Re: Formatting DateTime with an offset
- From: bruce barker <nospam@xxxxxxxxxx>
- Date: Fri, 15 Jun 2007 16:35:08 -0700
DateTime a is sealed value type so you can not extend it. You will have to write a class that encapsulates it. then its ToString() can do what you want.
-- bruce (sqlwork.com)
Untitled wrote:
I have an application that stores all DateTime inforamtion in UTC..
However, this application will be accessed from arround the world. I
would like my users to be able to specify their prefered TimeZone.
their timezone.From then on, i would like all DateTime information to be displayed in
I have written the code to do the timezone conversion. Now what
remains is finding a way to make every DateTime display in my
application use this code and get converted. I've tried to use the
culture info, the DateTimeFormatInfo class, i've even tried to make my
own custom formatter. No matter what I do, I can't seem to get my
DateTime.ToString() to go through my conversion code.
I have a lot of web pages, going through every page and every grid and
manually making a conversion would be tedious and prone to error. I'd
rather have DateTime.ToString go through some kind of formatting that
i am completely in control over and then i can do my formatting and
converting there.
Any help?
- References:
- Formatting DateTime with an offset
- From: Untitled
- Formatting DateTime with an offset
- Prev by Date: Best way to cache a bunch of images on the client? Possible to "stream" image info for caching after inital page render?
- Next by Date: Re: Adding AJAX to an existing app
- Previous by thread: Formatting DateTime with an offset
- Next by thread: .NET 2.0, SQL 2005, and REPORTS
- Index(es):
Relevant Pages
|
|