at
System.Web.Mvc.Html.ChildActionExtensions.RenderAction(HtmlHelper
htmlHelper, String actionName, String controllerName, Object
routeValues)
at
ASP.PageViewsMacroPartialsInsertUmbracoFormWithTheme_cshtml.Execute()
in
C:\Work\branch\website\Views\MacroPartials\InsertUmbracoFormWithTheme.cshtml:line
48
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy()
at System.Web.Mvc.WebViewPage.ExecutePageHierarchy()
at
System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext
pageContext, TextWriter writer, WebPageRenderingBase startPage)
at Umbraco.Core.Profiling.ProfilingView.Render(ViewContext
viewContext, TextWriter writer)
at
Umbraco.Web.Mvc.ControllerExtensions.RenderViewResultAsString(ControllerBase
controller, ViewResultBase viewResult)
at Umbraco.Web.Macros.PartialViewMacroEngine.Execute(MacroModel
macro, IPublishedContent content)
at umbraco.macro.LoadPartialViewMacro(MacroModel macro)
at umbraco.macro.renderMacro(Hashtable pageElements, Int32 pageId)
at Umbraco.Web.UmbracoComponentRenderer.RenderMacro(macro m,
IDictionary`2 parameters, page umbracoPage)
at Umbraco.Web.Editors.MacroController.GetMacroResultAsHtml(String
macroAlias, Int32 pageId, IDictionary`2 macroParams)
at lambda_method(Closure , Object , Object[] )
at
System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>cDisplayClass6_1.3(Object
instance, Object[] methodParameters)
at
System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext
controllerContext, IDictionary`2 arguments, CancellationToken
cancellationToken)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Controllers.ApiControllerActionInvoker.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.ActionFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Controllers.ActionFilterResult.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.AuthorizationFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.AuthorizationFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Filters.AuthorizationFilterAttribute.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Controllers.ExceptionFilterResult.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Web.Http.Controllers.ExceptionFilterResult.
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task
task)
at
System.Web.Http.Dispatcher.HttpControllerDispatcher.
Inner Exception System.Web.HttpCompileException:
C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET
Files\root\cee63a63\317dd5fe\AppWebrender.cshtml.e38f7875.uuxcfpva.0.cs(50):
error CS0246: The type or namespace name 'WebViewPage<>' could not be
found (are you missing a using directive or an assembly reference?)
at System.Web.Compilation.AssemblyBuilder.Compile()
at System.Web.Compilation.BuildProvidersCompiler.PerformBuild()
at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath
virtualPath)
I've just tested this on a clean version of Umbraco 7.12.1 and Umbraco Forms 7.4.1 - it works.
There's obviously something different in your setup - is the RTE in a grid or anything?
Have you added all the necessary front end bits for forms to your master template?
I remember seeing a bug myself with the InsertUmbracoFormWithTheme.cshtml on a v7 install... for the life of me I can't remember what I did to fix it. I think it was something to do with how I was rendering the form (using some old code from elsewhere probably).
Might be worth comparing the version of the Views\MacroPartials\InsertUmbracoFormWithTheme.cshtml partial I have with yours - see if it is an upgrade issue?
@inherits Umbraco.Web.Macros.PartialViewMacroPage
@if (Model.MacroParameters["FormGuid"] != null)
{
var s = Model.MacroParameters["FormGuid"].ToString();
var theme = "";
var includeScripts = true;
@*
If a theme is provided as a macro parameter, forms will attempt to use custom theme files
ex: given the value "test", forms will look up views for the form and fields in a custom directory:
Form will be rendered with
/Views/Partials/Forms/Themes/test/form.cshml
Fields will be rendered with
/Views/Partials/Forms/Themes/test/FieldType/[fieldtypename].cshtml
If a file is not available in the custom directory, forms will fallback to the default files in
/Views/Partials/Forms/Themes/default/
*@
if(Model.MacroParameters.ContainsKey("FormTheme"))
{
theme = Model.MacroParameters["FormTheme"].ToString();
}
if (Model.MacroParameters.ContainsKey("ExcludeScripts"))
{
@*
Inverse the boolean - RenderAction Parameter expects it to be false for exclusion
But with default value for Macro Paramater boolean/checkbox being false
We want to ensure by default we include the scripts next to the form
*@
includeScripts = Model.MacroParameters["ExcludeScripts"].ToString() == "0";
}
var form = new Guid(s);
var recordGuid = Guid.Empty;
if (string.IsNullOrEmpty(Request.QueryString["recordId"]) == false)
{
Guid.TryParse(Request.QueryString["recordId"], out recordGuid);
}
Html.RenderAction("RenderForm", "UmbracoForms", new {formId = form, recordId = recordGuid, theme = theme, includeScripts = includeScripts });
}
Umbraco Forms Error
Hi There,
I've been trying to integrate umbraco forms into our website. we're using Umbraco 7.12.1 and Umbraco Forms 7.4.1.
I manually installed Umbraco Forms and then tried to put it via a RTE, but I got the error message below. I'm I missing something ?
Hi Darren,
I've just tested this on a clean version of Umbraco 7.12.1 and Umbraco Forms 7.4.1 - it works.
There's obviously something different in your setup - is the RTE in a grid or anything?
Have you added all the necessary front end bits for forms to your master template?
I remember seeing a bug myself with the InsertUmbracoFormWithTheme.cshtml on a v7 install... for the life of me I can't remember what I did to fix it. I think it was something to do with how I was rendering the form (using some old code from elsewhere probably).
Might be worth comparing the version of the Views\MacroPartials\InsertUmbracoFormWithTheme.cshtml partial I have with yours - see if it is an upgrade issue?
HTH
Steve
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.