Results 1 to 2 of 2

Thread: QProcess() to execute independent processes in c++ [linux]

  1. #1
    Join Date
    May 2011
    Location
    Middle East
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11

    Question QProcess() to execute independent processes in c++ [linux]

    Greetings,

    Am new to C++, Linux and Qt. I would like to execute a # of executable programs independently within my source code. I want to be able to monitor/control these processes by fetching PID, knowing process status, killing process and if the process executed successfully.

    I was considering system calls because they aren't safe, but I switched to fork()-exec() but now I stumbled on QProcess and it made me to change my mind. so what do you think?

    Also, I searched for QProcess examples but I didn't find any to assist me in understanding.

    Therefore, advice me upon this issue. Please!

    Thank you in advance!

  2. #2
    Join Date
    Jan 2006
    Location
    Napoli, Italy
    Posts
    621
    Thanks
    5
    Thanked 86 Times in 81 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QProcess() to execute independent processes in c++ [linux]

    Quote Originally Posted by shhtk View Post
    Am new to C++, Linux and Qt.
    Hi, this is a big problem: Qt is a C++ Toolkit; so you MUST know C++ to use it.

    QProcess allows you to do all what you want but you have to understand how it works. To do this you need to know about signal/slot mechanism.

    I suggest you to study about C++, then move to study Qt and try to apply your knowledge.
    A camel can go 14 days without drink,
    I can't!!!

Similar Threads

  1. QProcess does not execute Automator app in OSX 10.6
    By Markus in forum Qt Programming
    Replies: 1
    Last Post: 19th April 2010, 04:12
  2. How to use the QProcess to execute the Browser ?
    By eric0214 in forum Qt for Embedded and Mobile
    Replies: 7
    Last Post: 21st December 2009, 10:06
  3. How to use the QProcess to execute the Browser ?
    By eric0214 in forum Qt Programming
    Replies: 2
    Last Post: 17th November 2009, 06:18
  4. QProcess Bash in Event Filter (Multiple Processes)
    By Arsenic in forum Qt Programming
    Replies: 1
    Last Post: 8th November 2008, 08:42
  5. Replies: 1
    Last Post: 6th March 2007, 15:27

Tags for this Thread

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.