Skip to content

DateTime field

Vinh Nguyen

Asked Mar 30, 2006, 6:49 AM EST1 answer
Share
LinkedInX
Hello Everyone,
I has one of the source code line is: "DateTime startTimeSelecion = startDateTimePickerCarton.Value" but when I debug and saw only MM/DD/YYYY without HH:MM.  What do I need to do in order for me to be able to see MM/DD/YYYYY HH:MM.  The reason that I need to have Date & time values in order for me to select all the records from my table.  In my table has a date field as DateTime. Can someone help me.  Thanks 

1 Answer

Know the answer? Post it. Somebody with the same question will find it here.

  • 0
    What is your datetime picker control? Maybe there is a "format" property where you can specify the datetime format.
    Also, if you want to query data from db based on just the date ( and concerned about having date and time in the db field ), just use convert() function in the sql stored proc to convert to mm/dd/yyyy format and use the shortdate from your front end code..

    Hope this helps!

    Cheers!
    0