Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi, we are trying to integrate umbraco with our membership software iMIS. for event booking. We created a view file for view the details of the events
Here is the view file code
@model Events.Models.EventRegistrationModel
@using ClientDependency.Core.Mvc @{ Html.RequiresJs("~/scripts/events.js"); }
@using (Html.BeginUmbracoForm
if (Model.EventDetails.EventFull) { <p class="error">This event is now full, please contact the administration office if you have any queries.</p> } else if (Model.EventDetails.EventClosed) { <p class="error">@Model.EventDetails.CutOffMessage</p> } else if (!Model.EventDetails.CanRegister) { <p class="error" style="text-align: center;"><strong>Please <a href="#" onclick="HighlightLogin(); return false;">log in</a> to register for this event.</strong></p> <p class="error" style="text-align: center;"><strong>Non-members please <a href="/new-account">create a new account</a> if you do not have a login.</strong></p> } if (Model.EventDetails.EventPhoto.Length > 0) { <img class="EventLogo" src="data:image;base64,@System.Convert.ToBase64String(Model.EventDetails.EventPhoto)" /> } <p class="EventDescription">@Html.Raw(Model.EventDetails.EventDescription)</p> <p class="EventAddress">@Html.Raw(Model.EventDetails.EventAddress)</p> <p class="EventDirections">@Html.Raw(Model.EventDetails.EventDirections)</p> <p> </p> <div class="buttons"> @if (Model.EventDetails.CanRegister && (!Model.EventDetails.EventFull) && (!Model.EventDetails.EventClosed)) { if (Model.EventDetails.IsCompanyAdministrator) { <input class="EventButton NextButton pure-button pure-button-primary" type="submit" name="btnRegisterMe" value="Register Me"> <input class="EventButton NextButton pure-button pure-button-primary" type="submit" name="btnRegisterGroup" value="Register Colleagues"> } else { <input class="EventButton NextButton pure-button pure-button-primary" type="submit" name="btnRegister" value="Register"> } } else { <input class="EventButton NextButton pure-button pure-button-primary" type="submit" name="btnRegister" value="Register" disabled="disabled"> } </div> @Html.Hidden("ser_model", new Microsoft.Web.Mvc.MvcSerializer().Serialize(Model))
}
And a screenshot of the error:
Am I missing something in the view file? or is it something in the surface controller?
Please help, I would really appreciate that
Hi Hasan
It looks like you have Events doctype and Events class in your solution.
Try to specify what Events class are you going to use in 42 line.
Something like:
CustomNamespace.Events
Thanks,
Alex
Did you solve the issue? Share with our community, please )
Yes after working through it a whole day we figured the word Events was reserved and we were using Events.dll so we had to force the view file to use the dll saying @using Events = Events
Thanks a lot for your input Alex appreciate it :)
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
View file error
Hi, we are trying to integrate umbraco with our membership software iMIS. for event booking. We created a view file for view the details of the events
Here is the view file code
@using ClientDependency.Core.Mvc @{ Html.RequiresJs("~/scripts/events.js"); }
@using (Html.BeginUmbracoForm
}
And a screenshot of the error:
Am I missing something in the view file? or is it something in the surface controller?
Please help, I would really appreciate that
Hi Hasan
It looks like you have Events doctype and Events class in your solution.
Try to specify what Events class are you going to use in 42 line.
Something like:
Thanks,
Alex
Hi Hasan
Did you solve the issue? Share with our community, please )
Thanks,
Alex
Yes after working through it a whole day we figured the word Events was reserved and we were using Events.dll so we had to force the view file to use the dll saying @using Events = Events
Thanks a lot for your input Alex appreciate it :)
is working on a reply...