<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[[Solved] how to convert QDateTime to GMT Unix Stamp]]></title><description><![CDATA[<p dir="auto">I am trying to convert QDateTime to Unix Time Stamp</p>
<p dir="auto">QDateTime PubDate = audioFile-&gt;GetPublishingdate();</p>
<p dir="auto">uint UTC_Time = PubDate.toTime_t();</p>
<p dir="auto">For Today,s date "Mon 22. Sep 00:00:00 2014" I am getting this 1411358400 TimeStamp Generated</p>
<p dir="auto">if i use this website <a href="http://www.epochconverter.com/" target="_blank" rel="noopener noreferrer nofollow ugc">http://www.epochconverter.com/</a> to check timestamp it is correct if I select Local Time but I want to generate timestamp according to GMT Time Which is 1411344000 for today's Date. I tried various other things.</p>
<p dir="auto">I am not getting how to get this time stamp</p>
<p dir="auto">Thanks for help in advance</p>
]]></description><link>https://forum.qt.io/topic/46203/solved-how-to-convert-qdatetime-to-gmt-unix-stamp</link><generator>RSS for Node</generator><lastBuildDate>Sun, 19 Apr 2026 07:47:42 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/46203.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 22 Sep 2014 06:38:02 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to [Solved] how to convert QDateTime to GMT Unix Stamp on Mon, 22 Sep 2014 07:30:23 GMT]]></title><description><![CDATA[<p dir="auto">Thanks</p>
<p dir="auto">PutDate.setTimeSpec(Qt::UTC);</p>
<p dir="auto">This solved problem</p>
]]></description><link>https://forum.qt.io/post/244798</link><guid isPermaLink="true">https://forum.qt.io/post/244798</guid><dc:creator><![CDATA[bhupi012]]></dc:creator><pubDate>Mon, 22 Sep 2014 07:30:23 GMT</pubDate></item><item><title><![CDATA[Reply to [Solved] how to convert QDateTime to GMT Unix Stamp on Mon, 22 Sep 2014 07:01:01 GMT]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto"><em>PubDate</em> is using local time. You need to tell it to use UTC (GMT) time before you call <em>toTime_t()</em></p>
<p dir="auto">See the "QDateTime documentation":<a href="http://qt-project.org/doc/qt-5/qdatetime.html" target="_blank" rel="noopener noreferrer nofollow ugc">http://qt-project.org/doc/qt-5/qdatetime.html</a> for info about time zones and Qt::TimeSpec</p>
]]></description><link>https://forum.qt.io/post/244790</link><guid isPermaLink="true">https://forum.qt.io/post/244790</guid><dc:creator><![CDATA[JKSH]]></dc:creator><pubDate>Mon, 22 Sep 2014 07:01:01 GMT</pubDate></item></channel></rss>