Solved

How do I convert a Rogue Wave RWTime to a .NET DateTime?

Posted on 2008-06-19
2
524 Views
Last Modified: 2012-05-05
I am working with code using an old Rogue Wave C++ library.  I am trying to write C++/CLI code to convert a RWTime for use by some C# code (.NET DateTime).  An RWTime can provide me the number of seconds since 1/1/1901.  How can I convert these seconds into a .NET DateTime?  If there is a better way I wouldn't mind hearing about that also.
0
Comment
Question by:Voltus_WoW
2 Comments
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 500 total points
Comment Utility
you can do something like:

DateTime dt = (new DateTime(1901,1,1)).AddSeconds(yourRWTime value here);
0
 

Author Comment

by:Voltus_WoW
Comment Utility
That is exactly what I needed.  I didn't even see the AddSeconds() method.  All the examples on the web pointed me at TimeSpan.  Thanks for the help!
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Normally the drop down box control found in the .Net framework tools is able to select just one data and value at a time, which is displayed on the text area.   But what if you want to have multiple values to be selected in the drop down box? As …
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now