Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- perintah.Connection = kon
- perintah.CommandType = CommandType.Text
- perintah.CommandText = "INSERT INTO barang_tbl VALUES('" & TextBox1.Text & "'," &
- "'" & txt_nama.Text & "','" & txt_barang.Text & "','" & txt_jumlahbarang.Text & "', " &
- "'" & txt_satuanbarang.Text & g & "')"
- perintah.ExecuteNonQuery()
- mda.SelectCommand = perintah
- perintah.CommandText = "select * from barang_tbl"
- ds.Tables.Clear()
- mda.Fill(ds, "data")
- DataGridView1.DataSource = ds.Tables("data")
- kon.Close()
- MsgBox("Data Berhasil Disimpan..!!", MsgBoxStyle.Information, "Pesan")
- bersih()
- Catch ex As Exception
- MessageBox.Show("Query Error " & ex.Message)
- End Try
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement