Results 1 to 20 of 154

Thread: How to use separate threads for pushbuttons in QT (like SwingWorker in Java)

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #11
    Join Date
    Mar 2015
    Posts
    125
    Qt products
    Qt4 Qt5
    Platforms
    Windows

    Default Re: How to use separate threads for pushbuttons in QT (like SwingWorker in Java)

    If I define IThread::run() in Lister.cpp with definition of Lister::walk(QString path0), lower in the same file I got such errors with 2 modifications - should I define these 2 methods in different files or in inverse order?
    Qt Code:
    1. 1. void IThread::run()
    2. {
    3. static void Lister::walk(QString path0);
    4. }
    5.  
    6. ERRROR:invalid use of qualified-name 'Lister::walk'
    7.  
    8. 2.
    9. void IThread::run()
    10. {
    11. Lister::walk(QString);
    12. }
    13.  
    14. ERROR:expected primary-expression before ')' token
    To copy to clipboard, switch view to plain text mode 
    There is also run-time error with the argument of walk(pp) - so should I understand that I need just walk()?
    QString p="C:\\C";
    Object::connect: No such slot Lister::walk(pp) in ..\Filewalker2\main.cpp:32
    Last edited by artt; 20th December 2015 at 02:18.

Similar Threads

  1. Replies: 1
    Last Post: 1st April 2014, 08:48
  2. Destruction in separate threads
    By KevinKnowles in forum Qt Programming
    Replies: 3
    Last Post: 19th March 2012, 09:49
  3. Problem with QProcess in two separate threads
    By viheaho in forum Qt Programming
    Replies: 2
    Last Post: 18th March 2010, 22:52
  4. Replies: 1
    Last Post: 7th December 2009, 07:26
  5. Calling same method from separate threads
    By steg90 in forum Qt Programming
    Replies: 2
    Last Post: 19th July 2007, 08:55

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
  •  
Qt is a trademark of The Qt Company.