How do you format the date time to just date?
-
How do you format the date time to just date? for example, this is what i retrievedd from the database: 12/31/2008 12:00:00 AM, but i just want to show the date and no time.
-
How do you format the date time to just date? for example, this is what i retrievedd from the database: 12/31/2008 12:00:00 AM, but i just want to show the date and no time.
Hi Muhammad; This will display the date only
' Simulate date and time from the DB
Dim dt As DateTime = Now' This will display the date only
MessageBox.Show(dt.ToString("MM/dd/yyyy"))Fernando
-
How do you format the date time to just date? for example, this is what i retrievedd from the database: 12/31/2008 12:00:00 AM, but i just want to show the date and no time.
-
No need to ask the same question twice, but 7 minutes apart. If someone doesn't answer the first they ain't going to answer the second.
EliottA wrote:
If someone doesn't answer the first they ain't going to answer the second.
I'm afraid Fernando has proven you're wrong about that... :laugh:
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google - the quality and detail of your question reflects on the effectiveness of the help you are likely to get - use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
-
EliottA wrote:
If someone doesn't answer the first they ain't going to answer the second.
I'm afraid Fernando has proven you're wrong about that... :laugh:
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google - the quality and detail of your question reflects on the effectiveness of the help you are likely to get - use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets