|
■No72092 (とぅーぜ さん) に返信 > Dim Item As New DataGridViewRow > Dim Table As DataTable = DataGridView2.DataSource > '各列に入れたいデータ > With Item > .Cells(0).Value = "Test0" > .Cells(1).Value = "Test1" > .Cells(2).Value = "Test2" > End With > Table.Rows.Add(Item)
Dim Table As DataTable = DirectCast(DataGridView2.DataSource, DataTable) Table.Rows.Add("Test0","Test1", "Test2")
こんな感じでどうでしょう?
|