Hello All, i created a datagridview using sqldataadapter and a dataset. when there is a change inthe database, i created a refresh button so the datagridview can reload the data to show the updated datbase. This work good and all but the application doesn't get restarted much so after like 2 days the datagridview no longer shows the most updated data even when i'm re-clicking my refresh button.
the application is meant not to be restarted on a daily bases.
///////////////
string sql="Select * from Table.....";
SqlDataAdapter da = new SqlDataAdapter(sql,connectionstring);
DataSet ds = new DataSet();
da.Fill(ds,"TableName");
DataTable DT1 = ds.Table[0];
DataGridView1.DataSource=ds.Tables["TableName"];
the application is meant not to be restarted on a daily bases.
///////////////
string sql="Select * from Table.....";
SqlDataAdapter da = new SqlDataAdapter(sql,connectionstring);
DataSet ds = new DataSet();
da.Fill(ds,"TableName");
DataTable DT1 = ds.Table[0];
DataGridView1.DataSource=ds.Tables["TableName"];