[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

TIme Conversion

Posted on 2000-03-02
9
Medium Priority
?
162 Views
Last Modified: 2010-05-02
hi all
i have this figure with me..
951453068
IT is the number of seconds elapsed from midnight Jan 1, 1970.
I want it to be conerted into current date..
Please help ASAP
Regards
Nitin
0
Comment
Question by:khacharn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
9 Comments
 
LVL 18

Expert Comment

by:deighton
ID: 2576015
Dim x As Date
Dim i As Long

i = 951453068
x = DateAdd("s", i, DateSerial(1970, 1, 1))
MsgBox x
0
 
LVL 18

Expert Comment

by:deighton
ID: 2576017
Private Sub Command1_Click()
Dim x As Date
Dim i As Long

i = 951453068
x = DateAdd("s", i, DateSerial(1970, 1, 1))
MsgBox x
MsgBox Format(x, "long date")
End Sub
0
 
LVL 12

Expert Comment

by:roverm
ID: 2576025
MsgBox "Calculated date:" & Dateadd ("s", 951453068, cdate("01-01-1970"))


D'Mzzl!
RoverM
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 12

Expert Comment

by:roverm
ID: 2576029
deighton: sorry had the question open while building the answer ;-)) !

0
 

Author Comment

by:khacharn
ID: 2578991
hi deighton's.
I will give you full points..
One small question:
How to convert the same to current time..
Please help ASAP
Regards
Nitin
0
 
LVL 12

Accepted Solution

by:
roverm earned 15 total points
ID: 2579136
That's what my example does !
;-) RoverM
0
 

Author Comment

by:khacharn
ID: 2582526
Sorry Delington..
I like roverm's answer better..
Regards
Nitin
0
 

Author Comment

by:khacharn
ID: 2582528
Thanx Roverm
Regards
Nitin
0
 

Author Comment

by:khacharn
ID: 2582553
Actually its my mistake..
roverm instead of cdate() the code should use DateSerial(1970, 1, 1))
Thanx Delington..
sorry i can't give you the points..
But it your code works just fine for me..
Thanx
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

649 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