Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27554

VS 2010 Adding Row in DataGrid

$
0
0
I tried to add row in a datagrid.

Below is the code
Code:

Dim r As DataRow
r = Tbl.NewRow()
r("ITEM") = "Section 4(a)"
Tbl.Rows.Add(r)

The error message told that "Input string was not in a correct format.Couldn't store <Section 4(a)> in ITEM Column. Expected type is Int32.".

I dont understand why "Section 4(a)" is not acceptable.

Pls help.

Viewing all articles
Browse latest Browse all 27554

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>