Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
DataGridView1.Rows.Add(1)
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(0).Value = (DataGridView1.RowCount - 1)
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(0).Value = TextBox1.Text
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(1).Value = TextBox2.Text
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(2).Value = TextBox3.Text
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(3).Value = ComboBox1.Text()
DataGridView1.Rows(DataGridView1.RowCount - 2).Cells(4).Value = TextBox4.Text
End Sub
End Class
Komentar
Posting Komentar