# Gridview Use the following code,A problem occurred

**URL:** <https://discuss.workflowgen.com/t/gridview-use-the-following-code-a-problem-occurred/1924>\
**Category:** General WorkflowGen Discussion\
**Created:** [August 20, 2021, 7:35am UTC](https://discuss.workflowgen.com/t/gridview-use-the-following-code-a-problem-occurred/1924 "2021-08-20T07:35:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![song](https://avatars.discourse-cdn.com/v4/letter/s/ecd19e/32.png) [@song](https://discuss.workflowgen.com/u/song)\
**Post date:** [August 20, 2021, 7:35am UTC](https://discuss.workflowgen.com/t/gridview-use-the-following-code-a-problem-occurred/1924/1 "2021-08-20T07:35:27Z")

</div>

> [@Gridview Data](https://discuss.workflowgen.com/t/gridview-data/1155/2):
>
> ```auto
> this.FormData.Tables["REQUEST_GRIDVIEW1"].Rows.Clear();
> System.Data.DataRow newRow = this.FormData.Tables["REQUEST_GRIDVIEW1"].NewRow();
> newRow[0] = "Value of 1st column";
> newRow[1] = "Value of 2nd column";
> newRow[2] = "Value of 3rd column";
> this.FormData.Tables["REQUEST_GRIDVIEW1"].Rows.Add(newRow);
> this.FormData.Tables["REQUEST_GRIDVIEW1"].AcceptChanges();
> this.SaveFormData(this.FormData);
> this.BindFormDataToFields(this.FormData);
> 
> ```

![image](https://canada1.discourse-cdn.com/flex030/uploads/workflowgen/original/1X/70b1fec333889dc189ac3ecbcd8a2d74d7d63cdb.png)

Editing other gridview ，The button is misaligned
