VB.net DataTable colum type

Hi

I want to find out whether a column in my DataTable is numeric, date or text type.
How do I do this?
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAsked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Connect With a Mentor Billing EngineerCommented:
as written above:
the DataTable has a Columns property, and you just examine that one, taking the column item you are interested in...
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
you have the DataColumn's datatype (Columns collection on the DataTable):
http://msdn.microsoft.com/en-us/library/system.data.datacolumn.datatype%28v=vs.110%29.aspx
0
 
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAuthor Commented:
Hi

Thanks. I am working with an existing  Datatable pulled from SQL so I don't know
the column types. What VB.net code do I use to retrieve these types?

Thanks
0
 
Murray BrownMicrosoft Cloud Azure/Excel Solution DeveloperAuthor Commented:
My mistake. Thanks very much Guy
Murray
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.