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

Edit Row in Grid

Hi,

i have created data grid. i want to edit rows of the grid. how can i do this ?

5 Replies

NK Neelakandan Kannan Syncfusion Team December 13, 2014 05:17 AM UTC

Hi Dev,

 

Thank you for your interest in Syncfusion products.

 

We regret to let you know that we could not able to clearly understand your query. We need some more details regarding your scenario. Here we have provided the solution that we understood.

If you want to change the values of the cells in Grid, you can use Text or CellValue property or QueryCellInfo event. Please make use of below code,

 

Code Snippet:

 

this.gridControl1[2, 5].CellValue = "Sample_Text";

 

this.gridControl1.QueryCellInfo += new GridQueryCellInfoEventHandler(gridControl1_QueryCellInfo);

void gridControl1_QueryCellInfo(object sender, GridQueryCellInfoEventArgs e)

        {

            if (e.RowIndex == 2 && e.ColIndex == 5)

            {

                e.Style.CellValue = "Sample_Text";

            }

        }

 

Please let me know if I misunderstood your query.

 

Regards,

Neelakandan



DE dev December 19, 2014 07:49 AM UTC

Thanx kannan it solved my problem. :)



NK Neelakandan Kannan Syncfusion Team December 22, 2014 04:03 AM UTC

Hi Dev,

 

Thank you for your update.

 

Please let us know if you want any assistance on this. We will assist you as soon as possible.

 

Regards,

Neelakandan



AS A Stern replied to Neelakandan Kannan March 27, 2018 10:17 AM UTC

Hi Dev,

 

Thank you for your interest in Syncfusion products.

 

We regret to let you know that we could not able to clearly understand your query. We need some more details regarding your scenario. Here we have provided the solution that we understood.

If you want to change the values of the cells in Grid, you can use Text or CellValue property or QueryCellInfo event. Please make use of below code,

 

Code Snippet:

 

this.gridControl1[2, 5].CellValue = "Sample_Text";

 

this.gridControl1.QueryCellInfo += new GridQueryCellInfoEventHandler(gridControl1_QueryCellInfo);

void gridControl1_QueryCellInfo(object sender, GridQueryCellInfoEventArgs e)

        {

            if (e.RowIndex == 2 && e.ColIndex == 5)

            {

                e.Style.CellValue = "Sample_Text";

            }

        }

 

Please let me know if I misunderstood your query.

 

Regards,

Neelakandan


Hello


SN Sindhu Nagarajan Syncfusion Team March 28, 2018 04:28 AM UTC

Hi Stern, 
  
Thanks for the update.  
  
Please let us know if you need any further assistance on this. 
  
Regards, 
Sindhu  


Loader.
Live Chat Icon For mobile
Up arrow icon