Thanks for your help! I go into Developer > Partial view macro files > Then created my PVM file. This also created a Macro which links to this PVM file. I then insert the macro on the template.
I used the menu at the top of the editor and clicked insert macro and selected the macro that was created when I created the Partial view file. It wasn't using the @HTML.render("pvfileName") code as it only displayed this as text so i used the usual insert macro??
Cannot bind source type Umbraco.Web.Models.PartialViewMacroModel to model type Umbraco.Core.Models.IPublishedContent.
I have created a Partial View which resides inside a Macro.
When i add the macro to my webforms template i get the error
"Cannot bind source type Umbraco.Web.Models.PartialViewMacroModel to model type Umbraco.Core.Models.IPublishedContent."
If i add just the MVC code then it displays the text only and doesnt render anything?
Could someone advise how to come over this issue?
Hi J
How did you add the macro to your template? can you show the razor code?
Thanks,
Alex
Hey Alex,
Thanks for your help! I go into Developer > Partial view macro files > Then created my PVM file. This also created a Macro which links to this PVM file. I then insert the macro on the template.
This is a snippet of what i have inside this file
Thanks
How did you add macro to a template?
I used the menu at the top of the editor and clicked insert macro and selected the macro that was created when I created the Partial view file. It wasn't using the @HTML.render("pvfileName") code as it only displayed this as text so i used the usual insert macro??
is working on a reply...