We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to render the partial view content while unobtrusive mode is enabled?

Platform: ASP.NET MVC |
Control: General


There is no need to refer ej.unobtrusive.min.js file in every partial view page to render Syncfusion components while UnobtrusiveJavaScriptEnabled set as true.



When the UnobtrusiveJavaScriptEnabled is set as true in the web.config page then the control must be initialized by using the “ej.widget.init” method in the AJAX success function instead by referring “ej.unobtrusive.min.js” script file on every partial view page. Please refer to the below code:   



function click() { 
     url: '/Home/ToolsPartial', 
     success: onSuccess 
function onSuccess(result) { 



Please find the sample from the following location: Sample 



2X faster development

The ultimate ASP.NET MVC UI toolkit to boost your development speed.
You must log in to leave a comment
Bruno Figueiredo
Oct 03, 2017


I have a grid that is loaded in a partial view. If i use ej.widget.init(); my partial is rendered normaly and the grid works great, but if I use ej.widget.init($("#MYGridId"));  the grid is not rendered. 

My problem is that the partial view is loaded to a modal div from an event from another grid in edit mode. If I call ej.widget.init(); the grid that is in edit mode, just cancel the current edit.

Can you help me? why doesnt this ej.widget.init($("#MYGridId"));   work? 

My version is of ej.web.all.min.js is


Prasanna Kumar Viswanathan [Syncfusion]
Oct 04, 2017

Hi Bruno,


To render the Grid in partial view we need to mention the parent element(container id) id of syncfusion control in ej.widget.init() method. The ej.widget.init() method is used to initialize the control in partial view. In ajax Success method we get the partial view  elements in arguments and render inside the container using jQuery html method.


Find the code example :


<div id="container" style="width:70%;height:70%;border:1px solid">



@(Html.EJ().Grid<object>("Grid")                     .Datasource((IEnumerable<object>)ViewBag.datasource)


.ClientSideEvents(eve => eve.ActionComplete("complete"))





        function complete(args) {

            if (args.requestType == "beginedit") {



                        url: '/Home/ToolsPartial',

                        success: onSuccess




function onSuccess(result) {







Partial View







        .Columns(col =>


            col.Field("OrderID").HeaderText("Order ID").IsPrimaryKey(true).TextAlign(TextAlign.Right).Width(75).Add();

            col.Field("FirstName").HeaderText("First Name").Width(80).Add();

            col.Field("LastName").HeaderText("Last Name").Width(80).Add();




If we misunderstood your query please get back to us.



Prasanna Kumar N.S.V

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile