PC Review


Reply
Thread Tools Rate Thread

basic datetime format question

 
 
PJ6
Guest
Posts: n/a
 
      22nd Aug 2005
What's the easiest way to get a string from a datetime that omits the time?
I want to respect whatever local format there is for dates, so it can't
involve something like "mm/dd/yyyy".

Paul


 
Reply With Quote
 
 
 
 
PJ6
Guest
Posts: n/a
 
      22nd Aug 2005
Never mind... duh.

CDate(Item).ToShortDateString

"PJ6" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> What's the easiest way to get a string from a datetime that omits the
> time? I want to respect whatever local format there is for dates, so it
> can't involve something like "mm/dd/yyyy".
>
> Paul
>



 
Reply With Quote
 
Cor Ligthert [MVP]
Guest
Posts: n/a
 
      23rd Aug 2005
Paul,

I prefer this one
\\\
Dim datestring As String = Now.ToString("d")
///
I hope this helps,

Cor


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DateTime format question dev15 Microsoft Dot NET Compact Framework 2 21st Aug 2007 12:24 PM
DateTime format/manipulation question Andrew Wilhite Microsoft C# .NET 4 21st Sep 2004 11:17 PM
basic format question...I think !! JG Microsoft Excel Discussion 3 26th Aug 2004 01:10 PM
DateTime problem: how to create datetime format hh:mm:ss AM/PM without the date mimi Microsoft C# .NET 1 6th Aug 2004 08:28 PM
DateTime & string format question Trevor Balcom Microsoft C# .NET 4 6th Jan 2004 01:58 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:13 AM.