EdwardChan
Crownpeak Employee
Crownpeak Employee

FAQ - Error rendering input when editing a Component Definition

Question

Why am I getting an "Error rendering input. Unable to create component..." error when editing a Component Definition asset?

Answer

The Component Definition assets are assets generally found under the /Component Library/Component Definitions/ subfolder of your CMS projects folder. When you edit these assets, it attempts to load a preview of what the components input fields would look like. In doing so, it attempts to instantiate the library files that should have been created when you initially saved the Component Definition. These files would be found under the /Library/ subfolder of your project. The library files have a standard naming convention of Components_<ComponentName>Base.cs and Components_<ComponentName>.cs where <ComponentName> is the formatted name given to your Component Definition asset. The reason for the "Error rendering input.." error is because it could not instantiate the associated library files when trying to load the preview. A common cause of for this is compilation issues with unrelated library files. The CMS creates an assembly from all of the library files in the project so if there are compilation issues in any of the library files, the CMS would not update the assembly and would just use a previous working version. That means your Component Definitions' library files (Components_<ComponentName>Base.cs and Components_<ComponentName>.cs) may not have made it into the assembly.

To see if this is the case, attempt to re-compile all of your library files by right clicking on the /Library/ folder and selecting Recompile Library Files:

component-libraary-recompile.PNG

If there are any errors, you should get a popup on the lower right corner of the CMS indicating the errors. You can also open the notifications window in the upper right corner of the CMS to see the errors if any:

component-libary-notifiations.PNG

Alternately, you can check the content properties of the Component Definition asset to see if a "post_save_error" field has been added. This field should give point you more details on the compilation errors. You should see something like this:

component-library-definition-content.png

To see the content properties, select your Component Definition asset and then navigate to the Properties Tab > Content. You may need to enable the Properties tab first by checking off View > Properties in the top menu of the CMS. 

Labels (1)

Can't find what you are looking for?

Find Answers

Search our DXM Forum to find answers to questions asked by other DXM users.

Ask a Question

No luck? Ask a question. Our Product and Support teams are monitoring the Forum and typically respond within 48 hours.

Ask a Question