Results 1 to 3 of 3

Thread: [SOLVED] QDate is giving a different date

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Nov 2010
    Location
    planet earth
    Posts
    19
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default [SOLVED] QDate is giving a different date

    hi,

    i have a weird problem regarding on QDate. this is the code :

    Qt Code:
    1. QString strDate = "April 01, 1981";
    2. QDate date = QDate::fromString(strDate);
    To copy to clipboard, switch view to plain text mode 

    when i tried to display it again using date.toString("MMMM dd yyyy") = September 14 1752. what happened to my date?
    Last edited by xeroblast; 7th December 2010 at 04:01.

Similar Threads

  1. Giving reference to QThread
    By codeman in forum Qt Programming
    Replies: 3
    Last Post: 25th March 2010, 10:33
  2. OpenCASCADE sample for qt is giving problem
    By sujan.dasmahapatra in forum Qt Programming
    Replies: 1
    Last Post: 1st December 2009, 10:02
  3. giving main window a name?
    By oji in forum Qt Programming
    Replies: 2
    Last Post: 16th November 2009, 11:13
  4. How to default Date-Edit Widget to system date
    By JohnToddSr in forum Qt Tools
    Replies: 4
    Last Post: 17th January 2007, 19:18
  5. QFontMetrics not giving proper dimension
    By Gopala Krishna in forum Qt Programming
    Replies: 3
    Last Post: 7th October 2006, 15:00

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.