PC Review


Reply
Thread Tools Rate Thread

CultureInfo UseUserOverride short time format not available W2K

 
 
colin_young@yahoo.com
Guest
Posts: n/a
 
      11th May 2005
I am created a WinForms app on Windows 2000 and I would like to format
the time using the custom format string I have specified in the control
panel. I have the machine set to English (United States) and the time
format is HH:mm:ss. I'd like to use a short time format string (e.g. no
seconds), but the control panel doesn't allow me to set one.

Is there a work-around for W2K?

Thanks

Colin

 
Reply With Quote
 
 
 
 
Katy King
Guest
Posts: n/a
 
      14th May 2005
From: (E-Mail Removed)
|
| I am created a WinForms app on Windows 2000 and I would like to format
| the time using the custom format string I have specified in the control
| panel. I have the machine set to English (United States) and the time
| format is HH:mm:ss. I'd like to use a short time format string (e.g. no
| seconds), but the control panel doesn't allow me to set one.
|
| Is there a work-around for W2K?
|

You can use DateTime.ToString("t") to write the short time string. (Formats
"f" and "g" also use the short time format along with the date.)
If you need to set the short time format, you can set
DateTimeFormatInfo.ShortTimePattern and call DateTime.ToString with that
DateTimeFormatInfo as the format provider.

Katy

 
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
Military Time(Short Time Format) =?Utf-8?B?Qm9iYnk=?= Microsoft Access VBA Modules 6 20th Mar 2006 04:25 PM
Short Time Format =?Utf-8?B?TGVBbm4=?= Microsoft Access Reports 2 16th May 2005 07:28 PM
Short Time Format Error =?Utf-8?B?S2V0YW4=?= Microsoft Access Database Table Design 3 6th Apr 2005 03:20 AM
Using SUM with a short time format Ant Microsoft Access 4 16th Jun 2004 10:01 PM
How do I format datagrid column to short time? Me Microsoft ADO .NET 6 6th Oct 2003 12:10 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:58 AM.