Greetings everybody,

I have been trying to convert UTC time into local time.

Using ctime library, time_t, gmtime etc. But I am having nothing.

When I searched the web, I saw nothing but examples with this library...

I would like to ask you how could I convert UTC, a double , into local time?

By the way, I am reading UTC data from a file, in String^ format. And having run-time error...

I would be pleased if you could give me a hint.

Thanks in advance

Edited 2 Years Ago by m.a.u.

Might I ask you how I could convert String^ into time_t format?

This will probably solve my problem.

Thanks

Since you're already using C++/CLI, why not initialize a DateTime object with the String^ and then use the ToLocalTime method?

What exactly does the string contain? Is it a standard UTC format?

Deceptikon,

Thank you for your answer.

The content of the String^ is a number similar to "077243532.949" .

ctime/time.h have not worked,yet.

Thank you

Is that a Julian date format? I was assuming you had something like an ISO 8601 formatted date, but this complicates matters.

Deceptikon,

Thanks for your answers. It is exactly the current clock info. I need to only seperate data properly. So, this problem is solved.

Thanks

This question has already been answered. Start a new discussion instead.