Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Convert time from 22:10:10 to 10:10 pm ?
Message
 
 
To
25/05/2004 00:36:12
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00906711
Message ID:
00906866
Views:
12
Bonnie,
Yes, your suggestion works as follows:
string Test = "14:15:32";
System.Convert.ToDateTime( Test ).ToString("t")
Thank you you very much for your help!

>>Thank you for your help. I will look up help for this class (that much I can do <g>).
>
>No problem, Dmitry ... lemme know if you get it working.
>
>~~Bonnie
>
>
>>>Dmitry,
>>>
>>>If you want it to remain a string, you can use Convert.ToDateTime().ToShortTimeString() or .ToLongTimeString(). (I forget exactly what the formatted string will look like, but you can try it and see).
>>>
>>>~~Bonnie
>>>
>>>>Is there a function in C# that would convert time from a sting (in VFP table) of the Hour-Min-Seconds format to Hour-Minute am/pm?
>>>>
>>>>TIA.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform