hi..i have done the coding below
the code is working
but the only problem is that the datagrid wont show out the table
i have to click on the extesion that is in the datagrid (+) in order to show it
im not sure where i should post this..but can help me?
i wish the data to be show in datagrid after this code is complie
and the datagrid will show the data like a table
thank you in advance
Code:
Dim sql As String
Dim MyConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Application.StartupPath & "\LibrarySystem.mdb")
MyConnection.Open()
Dim da As New OleDbDataAdapter
sql = "SELECT e.Product_code, f.Item_code FROM Products e, Items f WHERE e.Product_code=f.Product_code"
da.SelectCommand = New OleDbCommand(sql, MyConnection)
Dim ds As DataSet = New DataSet
da.Fill(ds)
DG1.DataSource = ds
but the only problem is that the datagrid wont show out the table
i have to click on the extesion that is in the datagrid (+) in order to show it
im not sure where i should post this..but can help me?
i wish the data to be show in datagrid after this code is complie
and the datagrid will show the data like a table
thank you in advance