General information
Title:
Check if a table exist in a dataset
HI,
I want to fill a atble from specific data based on a parameter. Since the table will contains many queries values, I need to clear it before I use it again. The code I am using is :
if (MyDataset.Tables.Contains("MyTable"))
{
MyDataset.Tables["MyTable"].Clear();
}
The problem is that even if MyTable exists in the dataset, the program never enter the if because it seems that the if condition is wrong.
Is that right?
Thank you for your help,
Christian
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only