A
Andrew Mueller
Hello,
I have the following code:
DataSet myDataSet = new DataSet();
OleDbDataAdapter adapter = new OleDbDataAdapter(sb.ToString(),myConn);
adapter.MissingSchemaAction = MissingSchemaAction.AddWithKey;
int count = adapter.Fill(myDataSet,"ihrawdata");
foreach (DataTable table in myDataSet.Tables)
{
foreach (DataRow row in table.Rows)
{
return Convert.ToString(row[0]);
}
}
return "NONE";
}
How do I wait for the query to have completed before attempting to fill the
dataset object? I think I am running into a timing issue of trying to fill
to fast because I am making many successive queries and I would like to test
my theory.
Thanks!
PS - Thread.Sleep does not work because it stops everything apparently. I
do not want to stop the query process, just wait for the completed data from
my table, ihrawdata.
Andrew Mueller
I have the following code:
DataSet myDataSet = new DataSet();
OleDbDataAdapter adapter = new OleDbDataAdapter(sb.ToString(),myConn);
adapter.MissingSchemaAction = MissingSchemaAction.AddWithKey;
int count = adapter.Fill(myDataSet,"ihrawdata");
foreach (DataTable table in myDataSet.Tables)
{
foreach (DataRow row in table.Rows)
{
return Convert.ToString(row[0]);
}
}
return "NONE";
}
How do I wait for the query to have completed before attempting to fill the
dataset object? I think I am running into a timing issue of trying to fill
to fast because I am making many successive queries and I would like to test
my theory.
Thanks!
PS - Thread.Sleep does not work because it stops everything apparently. I
do not want to stop the query process, just wait for the completed data from
my table, ihrawdata.
Andrew Mueller