How to Convert 10 digit Number to Date
-
Hi, I have one software which gives me 10 digit Number for date. How could I convert that 10 digit number to actual date. Example :- The output given by software is 1251983760 for the date 03-09-2009. Please help me to convert that number to actual date.
-
Hi, I have one software which gives me 10 digit Number for date. How could I convert that 10 digit number to actual date. Example :- The output given by software is 1251983760 for the date 03-09-2009. Please help me to convert that number to actual date.
-
can be the seconds since 1970/01/01 (or maybe 1969/12/31)
-
can be the seconds since 1970/01/01 (or maybe 1969/12/31)
I tried it: it´s the number of seconds since 1970/01/01 00:00
DateTime smq = new DateTime(1970, 1, 1);
Console.WriteLine("Date {0} + {1} seconds = {2}", smq.ToString(), 1251983760.ToString(), smq.AddSeconds(1251983760).ToString()); -
Happy to see you posting on C# forum. :)
Navaneeth How to use google | Ask smart questions
-
Happy to see you posting on C# forum. :)
Navaneeth How to use google | Ask smart questions
Well, I've started to lurk here to see if I can learn something new (the plan of learning .NET properly, which I had been procrastinating for a very long time). :) While in the process of reading posts and leeching knowledge off the C# Gurus, I may answer a couple of easy posts, being wrong here and there. You guys must be watchful and warn me on such occasions! :laugh:
It is a crappy thing, but it's life -^ Carlo Pallini
-
I tried it: it´s the number of seconds since 1970/01/01 00:00
DateTime smq = new DateTime(1970, 1, 1);
Console.WriteLine("Date {0} + {1} seconds = {2}", smq.ToString(), 1251983760.ToString(), smq.AddSeconds(1251983760).ToString());Thanks bro. That number was in seconds since 1970/01/01 00:00;