computer guy
Member
- Joined
- Feb 12, 2008
- Messages
- 18
- Programming Experience
- Beginner
Hello all,
I have a DataSet(dssongs) with a DataTable(dtsongs) on a form(songsForm).
I am adding rows to the dataTable using the following code:
If I then do:
I get "Count: 1", however if I go to another form and do:
I get "Count: 0".
How do I refer to a DataTable on another form?
Thank you
I have a DataSet(dssongs) with a DataTable(dtsongs) on a form(songsForm).
I am adding rows to the dataTable using the following code:
VB.NET:
Dim dr As DataRow = songsForm.dtSongs.NewRow
dr.Item("colSongFile") = file
dr.Item("colSongTitle") = ""
dr.Item("colSongAlbum") = ""
dr.Item("colSongArtist") = ""
dr.Item("colSongStatus") = "Queued"
songsForm.dtSongs.Rows.Add(dr)
If I then do:
VB.NET:
MsgBox("Count: " & dtSongs.Rows.Count)
I get "Count: 1", however if I go to another form and do:
VB.NET:
MsgBox("Count: " & songsForm.dtSongs.Rows.Count)
I get "Count: 0".
How do I refer to a DataTable on another form?
Thank you