|
-
Jul 11th, 2000, 10:06 PM
#1
Thread Starter
Junior Member
I'm pulling the registry key HKEY_LOCAL_MACHINESoftware\Microsoft\Windows NT\CurrentVersion\InstallDate on NT machines and the number contained in that key is something like 958778695. I'm guessing that the number is the number of seconds since whatever the start date was back in 1970 or so. I want to get an actual date out of the thing, i know in C++ there is a function that converts it, is there once for VB or do i need to code my own?
-
Jul 11th, 2000, 10:10 PM
#2
Frenzied Member
It's Just CDate(lngMyValue)
Most Variables Can Be Converted into one another using a similar Function
CInt() converts to integer
CLong() Converts ti long
CSTR ConVerts To String
CVar converts to Variant
I can't remember the rest, but there's a pattern, just improvise till you ving the Richt one. It's like the C++ Cast Operator.
-
Jul 11th, 2000, 10:20 PM
#3
Thread Starter
Junior Member
That just causes an overflow. I know the basic type conversions for Vb but they won't do this as far as i know. If you do the calculations by hand it comes out to ~29-30 years which is about right for the install date on these machines.
-
Jul 11th, 2000, 10:32 PM
#4
Thread Starter
Junior Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|