Populating a datagrid with dateTime columns

LostProgrammer

Well-known member
Joined
Jan 17, 2003
Messages
123
Hi everyone, got a question for you. When I fill my dataset and then add it to my datagrid. My sql datetime values only show up as mm/dd/yyyy. But what I need is for the time to show up also. Can anyone explain to me how I might fix this problem?

Thanks much

Chris
 
Try setting the DataColumns DataType property to the type of
a DateTime:

Code:
ds.Columns("whatever").DataType = Type.GetType("System.DateTime")
 
Back
Top