• Up and running in one day
  • Share information any time & any place
Error compiling template "Designs/PIMconnect_generated/Paragraph/ModuleOnlyParagraph.cshtml"
Line 33: A local variable named 'paragraphID' is already defined in this scope

1 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 2 @using Dynamicweb; 3 @using Dynamicweb.Content.Items; 4 @using Bluedesk.DynamicWeb.ItemTypes; 5 6 @{ 7 var paragraphID = Pageview.CurrentParagraph.ID; 8 ModuleOnlyParagraph _data = ItemManager.Storage.GetById<ModuleOnlyParagraph>(Pageview.CurrentParagraph.ItemId ?? "0"); 9 var paragraphID = Pageview.CurrentParagraph.ID; 10 } 11 12 @if (!string.IsNullOrWhiteSpace(GetString("ParagraphModule"))) 13 { 14 <section class="container py-4" data-paragraphid="@paragraphID" id="@paragraphID"> 15 @_data.Header.HeaderFormatted("mainheader") 16 17 @_data.SubHeader.HeaderFormatted() 18 19 @GetString("ParagraphModule") 20 </section> 21 } 22
To Top