473,503 Members | 9,057 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Get 13 digit datetime equivalent

Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.
Nov 21 '05 #1
5 3143
Example?
"anony" <no**@m.com> wrote in message
news:0Z********************@tornado.tampabay.rr.co m...
Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.

Nov 21 '05 #2
Hi,

Now.ToOADate

http://msdn.microsoft.com/library/de...adatetopic.asp

Ken
---------------------
"anony" <no**@m.com> wrote in message
news:0Z********************@tornado.tampabay.rr.co m...
Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.

Nov 21 '05 #3
Anony,

A datetime's Ticks property contains the raw number that represents that
datetime's date and time.

Kerry Moorman

"anony" wrote:
Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.

Nov 21 '05 #4
anony,
What specifically do you mean by "its 13 digit numeric value"?

Especially consider that a DateTime has more then 13 "digits" of data...
(there are 21 "digits" of data...

You could possible use DateTime.ToString to convert the elements of a
DateTime to a string in the format you desire.

Dim value As DateTime = DateTime.Now
Debug.WriteLine(value.ToString("yyyyMMddHHmmssffff fff"), "now")

For details on custom datetime formats see:

http://msdn.microsoft.com/library/de...matstrings.asp

For information on formatting in .NET in general see:
http://msdn.microsoft.com/library/de...ttingtypes.asp

Hope this helps
Jay

"anony" <no**@m.com> wrote in message
news:0Z********************@tornado.tampabay.rr.co m...
Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.

Nov 21 '05 #5
I was thinking of the time portion having 13 digits. Thanks to all who
responded.

"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in message
news:uw**************@TK2MSFTNGP10.phx.gbl...
anony,
What specifically do you mean by "its 13 digit numeric value"?

Especially consider that a DateTime has more then 13 "digits" of data...
(there are 21 "digits" of data...

You could possible use DateTime.ToString to convert the elements of a
DateTime to a string in the format you desire.

Dim value As DateTime = DateTime.Now
Debug.WriteLine(value.ToString("yyyyMMddHHmmssffff fff"), "now")

For details on custom datetime formats see:

http://msdn.microsoft.com/library/de...matstrings.asp

For information on formatting in .NET in general see:
http://msdn.microsoft.com/library/de...ttingtypes.asp

Hope this helps
Jay

"anony" <no**@m.com> wrote in message
news:0Z********************@tornado.tampabay.rr.co m...
Hi,

If I have a datetime, how do I display it as its13 digit numeric value?

Thanks.


Nov 21 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
401
by: San | last post by:
We are facing problem in converting the DateTime into equivalent long value in .NET, we need to pass this long value back to Java server. is this possible? if yes please send us some suggestion on...
16
10441
by: PK9 | last post by:
I have a string variable that holds the equivalent of a DateTime value. I pulled this datetime from the database and I want to strip off the time portion before displaying to the user. I am...
2
9451
by: Imran Irfan via SQLMonster.com | last post by:
I have a field in a table that contains ten digit value representing a datetime. Is there any way to convert it to default datetime format Thanks -- Message posted via http://www.sqlmonster.com
1
2768
by: Adam Monsen | last post by:
Say I have the following datetime object: >>> from datetime import datetime >>> d = datetime(2005, 8, 10, 15, 43) I happen to know this is a local time from the Netherlands, so I assume the...
2
3800
by: nic | last post by:
hey, I always struggle with the following: I have an object obj with a property paydate (type = DateTime) Now, after instantiating the object and do several things, I want too check if my...
4
8895
by: Anon | last post by:
Hello All! I have written a simple app that auto downloads a file from a secure ftp, renames it, and moves it to a network location. Everything works great except the renaming part. I parse out...
9
4899
by: Phil B | last post by:
I am having a problem with a datetime from a web services provider The provider is sending the following SOAP response <?xml version="1.0" encoding="utf-8"?> <soap:Envelope...
0
1627
by: vijayalakshmi.venkataraman | last post by:
Hello, I have a .NET client that accesses a Java webservice. Let me first say that the client stub I got generated from the wsdl was incomplete and had to make changes to it manually to make it...
33
13280
by: Prasad | last post by:
Hi, Can anyone please tell me how to store a 13 digit number in C language ? Also what is the format specifier to be used to access this variable ? Thanks in advance, Prasad P
0
7193
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7264
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7449
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5562
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4992
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3160
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3148
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1495
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
371
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.