Results 1 to 2 of 2

Thread: QDomDocument problem !!!

  1. #1
    Join Date
    Jan 2006
    Posts
    185
    Thanks
    1
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default QDomDocument problem !!!

    I have no idea why I am getting this problem.

    Qt Code:
    1. if(!doc.setContent(messageIn))
    2. cout << "The message received from the client is not well formed XML\n";
    To copy to clipboard, switch view to plain text mode 

    I have included QDomDocument, and I get this error:

    message.cpp: In member function `void Message:arseMessage(QString)':
    message.cpp:28: error: request for member `setContent' in `doc', which is of non-class type `QDomDoc
    ument ()()'

    Why, why why ?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    5,372
    Thanks
    28
    Thanked 976 Times in 912 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QDomDocument problem !!!

    Quote Originally Posted by probine View Post
    Why, why why ?
    Because
    Qt Code:
    To copy to clipboard, switch view to plain text mode 
    is a forward declaration of a function that has no arguments and returns QDomDocument. Remove those "()" and everything will be OK.

Similar Threads

  1. QTimer problem ... it runs but never triggs
    By yellowmat in forum Newbie
    Replies: 4
    Last Post: 4th July 2006, 12:54
  2. Problem with bitBlt
    By yellowmat in forum Newbie
    Replies: 1
    Last Post: 5th April 2006, 14:08
  3. fftw problem
    By lordy in forum General Programming
    Replies: 1
    Last Post: 16th March 2006, 21:36
  4. Replies: 16
    Last Post: 7th March 2006, 15:57
  5. Adding whitespace in QDomDocument
    By jakamph in forum Newbie
    Replies: 4
    Last Post: 6th February 2006, 22:06

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.