BoldSignEasily embed eSignatures in your .NET applications. Free sandbox with native SDK available.
Hi Minh,
Thanks for using Syncfusion Products.
Query 1 : “How can I keep the Update button enabled so I can edit multiple rows and it's only disabled when I actually click it?”
We suggest you to use batchEditing feature for the above query. In batch editing we can able to edit multiple rows and we can update all the edited records at one time.
Please refer the below online sample for batch editing feature:
Link : http://mvc.syncfusion.com/demos/web/grid/batchediting
For your convenience we have created a sample and sample can be downloaded from the below link
Query 2 : “What is the code to refresh the grid because I might need to use it in jquery at some points”
To refresh the grid, we suggest you to use refreshContent method in ejGrid.
We have already created a UG documentation for the refreshContent api. So, please refer the below link
Link : http://help.syncfusion.com/UG/JS_CR/ejGrid.html#refreshContent
Query 3 : “how can I attach an Action method to the Delete or Update button”
For this query, we suggest you to use URL Adaptor or remoteSave Adaptor. We can map CRUD operation inGridto Server-Side Controller action using the properties “InsertURL”, “UpdateURL” and “RemoveURL”. In the below attached sample, we use batchediting with URL Adaptor and for batchediting with URL Adaptor and for batcheditingwe map CRUD operation using the property Batch URL.
Please find the below code snippet :
@(Html.EJ().Grid<MvcApplication14.OrdersView>("FlatGrid") .Datasource(ds => ds.URL("BatchDataSource").BatchURL("BatchUpdate").Adaptor(AdaptorType.UrlAdaptor)) .AllowPaging() /*Paging Enabled*/ .EditSettings(edit => { edit.AllowAdding().AllowDeleting().AllowEditing().EditMode(EditMode.Batch); }) .ToolbarSettings(toolbar => { toolbar.ShowToolbar().ToolbarItems(items => { items.AddTool(ToolBarItems.Add); items.AddTool(ToolBarItems.Edit); items.AddTool(ToolBarItems.Delete); items.AddTool(ToolBarItems.Update); items.AddTool(ToolBarItems.Cancel); }); }) .Columns(col => { col.Field("OrderID").HeaderText("Order ID").IsPrimaryKey(true).TextAlign(TextAlign.Right).Width(75).Add(); col.Field("CustomerID").HeaderText("Customer ID").Width(80).Add(); col.Field("EmployeeID").HeaderText("Employee ID").TextAlign(TextAlign.Right).Width(75).Add(); col.Field("Freight").HeaderText("Freight").TextAlign(TextAlign.Right).Width(75).Format("{0:C}").Add(); col.Field("OrderDate").HeaderText("Order Date").TextAlign(TextAlign.Right).Width(80).Format("{0:MM/dd/yyyy}").Add(); col.Field("ShipCity").HeaderText("Ship City").Width(110).Add(); })) |
We have already created a UG documentation for the URL Adaptor and remoteSave Adaptor. Please refer the below link for the UG documentation
Link : http://help.syncfusion.com/ug/js/index.html#!Documents/crudoperationwithserverside.htm
Sample Link : http://www.syncfusion.com/downloads/support/forum/118796/Sample-1432307345.zip
Please get back to us if you have any further assistance on this,
Regards,
Prasanna Kumar N.S.V
Hi Minh,
Sorry for the inconvenience caused.
Please refer the below link for UG documentation link:
Link : http://help.syncfusion.com/cr/js
Please follow the steps for the refreshContent Api:
Steps : ejGrid -> Methods -> refreshContent
Please refer the below link for UG documentation of URL Adaptor and remoteSave Adaptor
Link : http://help.syncfusion.com/web
Please follow the steps for the documentation
Steps : Grid -> Concepts and Features -> Editing -> CRUD Operation With Server-Side
Please get back to us if you have any further assistance on this,
Regards,
Prasanna Kumar N.S.V