Results 1 to 14 of 14

Thread: My application crashes

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #13
    Join Date
    Aug 2008
    Location
    Ukraine, Krivoy Rog
    Posts
    1,963
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Thanked 370 Times in 336 Posts

    Default Re: My application crashes

    Quote Originally Posted by sophister View Post
    But I've got another question, following is your code to start another application:
    Qt Code:
    1. QProcess::startDetached(filename);
    To copy to clipboard, switch view to plain text mode 
    in this case a process will start as
    Unix: The started process will run in its own session and act like a daemon.

    Windows: Arguments that contain spaces are wrapped in quotes. The started process will run as a regular standalone process.
    in this case
    Quote Originally Posted by sophister View Post
    Are there some different effects between your way and mine? The following is my way to start it:
    Qt Code:
    1. QStringList arguments;
    2. arguments << "-style" << "motif";
    3. QProcess *myProcess = new QProcess(this);
    4. myProcess->start(path, arguments);
    To copy to clipboard, switch view to plain text mode 

    Thanks a lot!!
    you don't lose communication with a process, i.e. you can handle signals readyReadStandardError, readyReadStandardOutput etc.
    so, if you don't need to process signals then you can use only static methods for starting processes.
    Qt Assistant -- rocks!
    please, use tags [CODE] & [/CODE].

  2. The following user says thank you to spirit for this useful post:

    sophister (27th April 2009)

Similar Threads

  1. Replies: 1
    Last Post: 30th March 2009, 23:25
  2. Replies: 3
    Last Post: 3rd March 2009, 13:24
  3. dll + application
    By fpujol in forum Qt Programming
    Replies: 11
    Last Post: 15th April 2007, 19:37
  4. Replies: 5
    Last Post: 27th May 2006, 14:44

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.