Odd error when adding or editing Visual Function

Topics: General, Troubleshooting, Visual editor
Sep 22, 2011 at 10:44 PM

I'm getting the following error in the log when trying to add a Visual Function or edit a visual function.

System.InvalidOperationException: Missing file '/ProductPage.xml'
   at Composite.Data.Types.IFileServices.GetFile[T](String filePath)
   at Composite.Core.WebClient.Renderings.Template.TemplateInfo.PageTemplateFileWrapper..ctor(IPageTemplate pageTemplate)
   at Composite.Core.WebClient.Renderings.Template.TemplateInfo.GetTemplateDocument(Guid templateId)
   at Composite.Core.WebClient.Renderings.Template.TemplateInfo.GetRenderingPlaceHolders(Guid templateId)
   at Composite.Plugins.Elements.ElementProviders.VisualFunctionProviderElementProvider.EditVisualFunctionWorkflow.initializeCodeActivity_ExecuteCode(Object sender, EventArgs e)
   at System.Workflow.ComponentModel.Activity.RaiseEvent(DependencyProperty dependencyEvent, Object sender, EventArgs e)
   at System.Workflow.Activities.CodeActivity.Execute(ActivityExecutionContext executionContext)
   at System.Workflow.ComponentModel.ActivityExecutor`1.Execute(T activity, ActivityExecutionContext executionContext)
   at System.Workflow.ComponentModel.ActivityExecutorOperation.Run(IWorkflowCoreRuntime workflowCoreRuntime)
   at System.Workflow.Runtime.Scheduler.Run()

I don't recall ever seeing that xml file. Can anyone shed some light on this error?

Coordinator
Sep 23, 2011 at 9:06 AM

Hello,

On the Visual Function Settings tab check out what Preview template is selected, try to select other template.

Sep 26, 2011 at 10:01 PM
Edited Sep 26, 2011 at 10:02 PM

To clarify... I AM able to add a visual function that exists to a page. I am NOT able to to go into the Functions perspective and EDIT or CREATE a new Visual function. So, unfortunately, I can't even GET to the Visual Function Settings tab. :-(

Coordinator
Sep 29, 2011 at 8:38 AM

It looks like you had page template named ProductPage and somehow the template XML file ProductPage.xml was removed from folder ~\App_Data\PageTemplates\

If you are running on XML based site, check the file ~\App_Data\Composite\DataStores\Composite.Data.Types.IPageTemplate_Published.xml  and locate the row with PageTemplateFilePath="/ProductPage.xml'"

If the row exists, check if you have the file ProductPage.xml at the folder ~\App_Data\PageTemplates\. If no, then it was removed somehow. You can copy some existent template xml file and just name it as "ProductPage.xml" , then you can delete this template from C1 console -> Layout -> Page templates -> locate template ->  delete it.

Oct 12, 2011 at 6:01 PM

Thanks, that gives me a good idea of what happened. I'm on a SQL implementation, but I know where to look for the items.