No product found

Brug for rådgivning?

Udfyld felterne herunder - så kontakter vi dig for at høre, hvordan vi kan hjælpe dig.

Exception in template (Designs\nortec2018\Forms/Form\ProductContact.cshtml): System.NullReferenceException: Object reference not set to an instance of an object.
at CompiledRazorTemplates.Dynamic.bbafaaab.Execute()
at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateBase.cs:line 126
at RazorEngine.Templating.TemplateService.Run(ITemplate template, DynamicViewBag viewBag) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:line 608
at RazorEngine.Templating.TemplateService.Parse(String razorTemplate, Object model, DynamicViewBag viewBag, String cacheName) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:line 439
at RazorEngine.Razor.Parse[T](String razorTemplate, T model, String cacheName) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Razor.cs:line 276
at Dynamicweb.Rendering.Template.RenderRazorTemplate()
@inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> @using System.Web; @{ string id = GetGlobalValue("Global:Page.ID"); string productid = HttpContext.Current.Request.QueryString["ProductId"].ToString(); string currentUrl = id + "&ProductID=" + productid; } <div id="productcontactform"> @GetValue("Form.FormStart").ToString().Replace(id, currentUrl) @GetValue("Form.SystemFields") <div class="row"> @foreach (LoopItem field in GetLoop("Fields")) { string required = field.GetBoolean("Field.Required") ? "required" : ""; if (field.GetString("Field.Type") != "Textarea" && field.GetString("Field.Type") != "Submit") { <div class="form__field-group col--xs-12 col--sm-12 col--md-6"> <input type="@(field.GetString("Field.Type") == "TextInput" ? "text" : field.GetString("Field.Type"))" class="c_field" placeholder="@field.GetString("Field.Placeholder")" name="@field.GetString("Field.SystemName")" value="@field.GetString("Field.Value")" @required /> @field.GetValue("Field.Description") </div> } if (field.GetString("Field.Type") == "Textarea") { <div class="form__field-group col--xs-12 col--sm-12"> <textarea style="height: 38px;" placeholder="@field.GetString("Field.Placeholder")" class="c_field" name="@field.GetString("Field.SystemName")" value="@field.GetString("Field.Value")" @required></textarea> @field.GetValue("Field.Description") </div> } if (field.GetString("Field.Type") == "Submit") { <div class="form__field-group col--xs-12 col--sm-12"> <button class="button button--primary dw-mod" style="width: 200px; margin-right: 0; margin-left: auto;" onclick="Buttons.LockButton(event)" id="@field.GetInteger("Field.ID")" name="@field.GetString("Field.SystemName")" type="submit">@field.GetString("Field.Name")</button> </div> } } </div> @GetValue("Form.FormEnd") </div>