Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsBlogBlogNew Blog Release Status?New Blog Release Status?
Previous
 
Next
New Post
4/25/2007 12:58 AM
 

Hi,

Does Dim Mydate As Date=date.UtcNow.ToUniversalTime work ?


Do you use Oracle?  Then try GoldFish.Net

Get it from CNET Download.com! 

 
New Post
4/25/2007 9:17 AM
 

I will try the .ToUniversalTime...

But I do know that Date.UTCNow returns my time (EST) -1 hours


Maxiom TechnologyAntonio Chagoury | Microsoft MVP
Maxiom Technology
Professional .net & DotNetNuke Solutions
web: www.maxiomtech.com
blog: www.cto20.com
twitter: @antoniochagoury & @maxiomtech

 
New Post
4/25/2007 9:58 AM
 

Hi,

Technically Dim Mydate As Date=date.UtcNow.ToUniversalTime should worksince UtcNow would get your EST time information including daylight savings information and the ToUniversalTime should convert it to "universal" time.  The following,
Dim Mydate As Date = Date.Now.ToUniversalTime might also work in a similar way avoiding the UtcNow conversion.  I've taken a stable at alittle more detail below.  If these don't work let me know and I'll put together something else.

The UtcNow function should return a DateTime instance that represents the current local date and time expressed as the coordinated universal time (UTC).  Which explains the information you've been seeing due to Daylight Savings in the US.

Dim Mydate As Date=date.UtcNow

I believe that ToUniversalTime should fix this since it simply converts the value of the DateTime instance to coordinated universal time (UTC)


Dim Mydate As Date = Date.Now.ToUniversalTime

If that doesn't work let me know and I'll see if I can find something else to help.


Do you use Oracle?  Then try GoldFish.Net

Get it from CNET Download.com! 

 
New Post
4/25/2007 10:02 AM
 

Nope, that does not work.

ToUniversal, will besically convert it back to GMT 0. Even then, it is still one hour behind. Somehow it is not taking in consideration the DST.

I need to do some research on this.


Maxiom TechnologyAntonio Chagoury | Microsoft MVP
Maxiom Technology
Professional .net & DotNetNuke Solutions
web: www.maxiomtech.com
blog: www.cto20.com
twitter: @antoniochagoury & @maxiomtech

 
New Post
4/25/2007 10:17 AM
 

Looks like an issue with .Net after the DST update.

You can use Timezone.CurrentTimeZone.IsDaylightSavingTime(DateTimeObject) to determine if it is a daylight saving time value. 

Found a pretty good article on it, not 100% sure if this is your issue though,  http://articles.techrepublic.com.com/5100-3513-6160501.html

If you want I'll put together alittle research sample.  Just need to know what time you want to input and what time you're expecting.  My computer is already set to EST DST.

Will gladly help   you guys have been doing a great job.  So let me knowif there is anything that I can help with.

 


Do you use Oracle?  Then try GoldFish.Net

Get it from CNET Download.com! 

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsBlogBlogNew Blog Release Status?New Blog Release Status?


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out