Rama Tito
asked on
Error while update data in DataGridView from MYSQL
Hi ,
i am facing error while try out select data from mysql to DGV, my command as follows: -
cmd = "Select Top 200 idMasterSMSdB as [No],Sender as [Sender],TimeRec as [Time],MsgDataIn as [InComing SMS],MsgDataOut as [OutGoing SMS],Status as [Status]From mastersmsdb order by No desc";
da.SelectCommand = new MySqlCommand(cmd, myconint);
myconint.Open();
ds.Clear();
da.Fill(ds, "mastersmsdb");
DG1.DataSource = ds.Tables["mastersmsdb"];
bs.DataSource = ds.Tables["mastersmsdb"];
myconint.Close();
MYSQL.JPG
i am facing error while try out select data from mysql to DGV, my command as follows: -
cmd = "Select Top 200 idMasterSMSdB as [No],Sender as [Sender],TimeRec as [Time],MsgDataIn as [InComing SMS],MsgDataOut as [OutGoing SMS],Status as [Status]From mastersmsdb order by No desc";
da.SelectCommand = new MySqlCommand(cmd, myconint);
myconint.Open();
ds.Clear();
da.Fill(ds, "mastersmsdb");
DG1.DataSource = ds.Tables["mastersmsdb"];
bs.DataSource = ds.Tables["mastersmsdb"];
myconint.Close();
MYSQL.JPG
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.