<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[QProcess start new instance]]></title><description><![CDATA[<p dir="auto">I launch a new process using <strong>QProcess</strong>:</p>
<pre><code>QProcess* pobjProc(new QProcess());
pobjProc-&gt;start(strModule);
if ( !pobjProc-&gt;waitForStarted() ) {
    delete pobjProc;
    return;
}
const Q_PID cpid(pobjProc-&gt;pid());
mmpProcesses.insert(cpid, pobjProc);
</code></pre>
<p dir="auto">For testing I'm using <strong>gedit</strong> as the module to launch, the problem I'm seeing is that I want to be able to launch multiple instances and calling this again doesn't, it does re-focuses the already running instance of <strong>gedit</strong>.</p>
<p dir="auto">Do I need to add something to indicate new instance intended?  This is using Qt 4.8</p>
<p dir="auto">[Edit] I've also tried the using <strong>startDetached</strong> same result, only one instance is launched.</p>
]]></description><link>https://forum.qt.io/topic/134381/qprocess-start-new-instance</link><generator>RSS for Node</generator><lastBuildDate>Thu, 19 Nov 2026 02:26:54 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/134381.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 16 Feb 2022 09:20:24 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to QProcess start new instance on Wed, 16 Feb 2022 09:38:12 GMT]]></title><description><![CDATA[<p dir="auto">This is a behavior of your app you're starting - look for a command line argument to allow more than one instance of this application.</p>
]]></description><link>https://forum.qt.io/post/702766</link><guid isPermaLink="true">https://forum.qt.io/post/702766</guid><dc:creator><![CDATA[Christian Ehrlicher]]></dc:creator><pubDate>Wed, 16 Feb 2022 09:38:12 GMT</pubDate></item><item><title><![CDATA[Reply to QProcess start new instance on Wed, 16 Feb 2022 09:43:09 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/christian-ehrlicher">@<bdi>Christian-Ehrlicher</bdi></a> , typical, I picked this application at random just to test and it does indeed have an argument <strong>--new-window</strong> to launch a new instance.</p>
]]></description><link>https://forum.qt.io/post/702768</link><guid isPermaLink="true">https://forum.qt.io/post/702768</guid><dc:creator><![CDATA[SPlatten]]></dc:creator><pubDate>Wed, 16 Feb 2022 09:43:09 GMT</pubDate></item><item><title><![CDATA[Reply to QProcess start new instance on Wed, 16 Feb 2022 09:38:12 GMT]]></title><description><![CDATA[<p dir="auto">This is a behavior of your app you're starting - look for a command line argument to allow more than one instance of this application.</p>
]]></description><link>https://forum.qt.io/post/702766</link><guid isPermaLink="true">https://forum.qt.io/post/702766</guid><dc:creator><![CDATA[Christian Ehrlicher]]></dc:creator><pubDate>Wed, 16 Feb 2022 09:38:12 GMT</pubDate></item></channel></rss>