|
-
Jul 27th, 2000, 05:56 AM
#1
Thread Starter
New Member
Good day, I'm looking for anybody who has seen or written a function that converts a normal VB6 Date to the UNIX data format. I believe the format is the number of seconds since 1970??
Thanks
-
Jul 27th, 2000, 09:39 AM
#2
Fanatic Member
Thought I would make you laugh and roll your eyes
Dim b As Variant
Dim c As Variant
Dim d As Long
c = 60 * 60
c = c * 24
d = ((Format(Now, "yyyy") - 1971)) * 365
Do Until Format(Now - d, "yyyymmdd") = "19700101"
d = d + 1
Loop
c = d * c
b = (Format(Now, "hh:mm:ss"))
b = ((Val(Left$(b, 2) * 60) + Val(Mid(b, 4, 2))) * 60) + Val(Mid(b, 7, 2))
MsgBox Val(c) + Val(b)
Kurt Simons
[I know I'm a hack but my clients don't!]
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
|