Im trying to render an item in a paragraph razor template.
I get the item with:
Dynamicweb.Content.Items.Item item = Dynamicweb.Content.Items.ItemManager.Storage.GetById("Standard_Content", "1");
Then I tried this:
@RenderItem(item);
That results in a:
System.Reflection.TargetParameterCountException: Parameter count mismatch.
I also tried to this:
Dynamicweb.Content.Items.Rendering.Renderer r = new Dynamicweb.Content.Items.Rendering.Renderer();
Dynamicweb.Rendering.Template t = new Dynamicweb.Rendering.Template("ShowItem/Content.cshtml");
Dynamicweb.Content.Items.Item i = Dynamicweb.Content.Items.ItemManager.Storage.GetById("Standard_Content", "1");
r.RenderItem(i, t);
System.Web.HttpContext.Current.Response.Write(t.Output());
No errors but no output either.
Any suggestions?
Regards / Aki