How do create a DataTable in C#?

I did like this:

 DataTable dt = new DataTable();
 dt.clear();
 dt.Columns.Add("Name");
 dt.Columns.Add("Marks");

How do I see the structure of DataTable?

Now I want to add ravi for Name and 500 for Marks. How can I do this?

13 Answers
13

Leave a Reply

Your email address will not be published. Required fields are marked *