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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Save Additional Parameter with grid data

Thread ID:





140577 Oct 26,2018 02:39 AM UTC Oct 26,2018 07:12 AM UTC ASP.NET Core - EJ 2 1
Tags: DataGrid
Asked On October 26, 2018 02:39 AM UTC

Dear Syncfusion Team

Can you advice.

Currently i have the form with few field (dropdown) with datagrid (using ejs-grid mode normal).
During the grid CRUD, i want to bring also the information outside from the grid to save. The details as per in attachment.

Appreciate on your feedback


Attachment: Support_1_a52f5815.rar

Venkatesh Ayothi Raman [Syncfusion]
Replied On October 26, 2018 07:12 AM UTC

Hi Haryzad, 

Thanks for contacting Syncfusion Support. 

You can achieve your requirement by using the query property of the Grid component. We have prepared a simple sample based on your requirement in which we have added the additional parameter to the Grid query property in the actionBegin event which will be triggered before save the edited data. Please refer to the below code example, documentation link and sample link. 

<div class="control-wrapper"> 
    <div id="default" style='width:50%'> 
        Document Type: 
        <ejs-dropdownlist id="type" dataSource="@(new List<string>() { "PDF", "Excel", "CSV" })" placeholder="Select a type" popupHeight="220px"> 
<ejs-grid id="Grid" query="new ej.data.Query().addParams('type', 'default')" actionBegin="begin" height="273" toolbar="@(new List<string>() { "Add", "Edit", "Delete", "Cancel", "Update" })"> 
     .  .  .. 
    function begin(e) { 
        var grid = document.getElementsByClassName('e-grid')[0].ej2_instances[0]; 
        var type = document.getElementById('type').ej2_instances[0]; 
        if (e.requestType == "save") {    // triggers before saving the data          
            grid.query.params.filter((e) => e.key == 'type')[0].value = type.value; 

public ActionResult Update([FromBody] CRUDModel myObject) 
            var ord = myObject.Value; 
            OrdersDetails val = orddata.Where(or => or.OrderID == ord.OrderID).FirstOrDefault(); 
            val.OrderID = ord.OrderID; 
            .  .  . 
            return Json(myObject.Value); 
public class CRUDModel 
            public OrdersDetails Value { get; set; } 
            public string type { get; set; } 
            .  .  . 



Please let us know if you have any further assistance on this. 
Venkatesh Ayothiraman. 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

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

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