BoldDeskBoldDesk is now live on Product Hunt with a special offer: 50% off all plans. Let's grow together! Support us.
Basic steps for adding EJMVC components in the MVC application:
Adding References and Assemblies
After creating an MVC application, add the necessary dlls to your application to render the EJMVC components. You can refer the page no 147 (in the documentation which is attached above) to know about adding the dlls from GAC location. In page number 149 we have explained how to refer the assemblies from installed location.
After adding required dlls, you have to register the assemblies in web.config in appropriate location as shown below.
<compilation debug="true" targetFramework="4.5.2"> <assemblies> <!--Syncfusion.Core dll is not needed. we have removed this dll in our latest version 13.2.0.34--> <add assembly="Syncfusion.EJ, Version=13.2450.0.29, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89"/> <add assembly="Syncfusion.EJ.Mvc, Version=13.2500.0.29, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89"/> </assemblies> </compilation> |
Checking unobtrusivejavascript state in web.config file:
Ensure whether the Unobtrusive setting is enabled or disabled. By default it will be in enabled state. If UnobtrusiveJavaScript is set to true means we need to add the script file ej.unobtrusive.min.js file in our application. If the value is set to false means we need to add EJ().ScriptManager().
<appSettings> <add key="ClientValidationEnabled" value="true"/> <add key="UnobtrusiveJavaScriptEnabled" value="false"/> |
For more details, please refer page 155 in the documentation.
Adding namespaces.
Please add the necessary namespaces in the web.config file as shown below.
<namespaces> <add namespace="Syncfusion.JavaScript"/> <add namespace="Syncfusion.MVC.EJ"/> </namespaces> |
For more details about namespaces, please refer page 155 in the documentation.
Adding Scripts and CSS reference.
To render the Syncfusion MVC controls, it is necessary to refer the required CSS and Script files into your application. Please refer from Page number 156 in to know about the scripts and CSS reference.
Using the helper to render the components.
After completing the above steps successfully, now you can render our components by using the Helper, as shown below
@Html.EJ().DatePicker(“date”) |