<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;"><DIV>Hi John,</DIV>
<DIV>&nbsp;</DIV>
<DIV>I modified CMakeList.txt file in qtevents folder with the following entry:</DIV>
<DIV>&nbsp;SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /subsystem:windows"), ran CMake and generated a new VS2008 Solution file. However, my project properties did not reflect this change.&nbsp;My linker properties&nbsp;still show /subsystem:console. </DIV>
<DIV>&nbsp;</DIV>
<DIV>The good news is that the console&nbsp;didnot pop up after manually&nbsp;setting:</DIV>
<DIV>SubSystem=&nbsp;Windows (/SUBSYSTEM:WINDOWS)</DIV>
<DIV>in VS 2008.</DIV>
<DIV>&nbsp;</DIV>
<DIV>Thank you.</DIV>
<DIV><BR><BR><BR>--- On <B>Mon, 4/6/09, John Drescher <I>&lt;drescherjm@gmail.com&gt;</I></B> wrote:<BR></DIV>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: rgb(16,16,255) 2px solid"><BR>From: John Drescher &lt;drescherjm@gmail.com&gt;<BR>Subject: Re: [vtkusers] How to hide the console for a VTK/Qt app<BR>To: "Jim" &lt;jiksed@yahoo.com&gt;, "VTK" &lt;vtkusers@vtk.org&gt;, "Cmake Mailing List" &lt;cmake@cmake.org&gt;<BR>Date: Monday, April 6, 2009, 3:15 PM<BR><BR>
<DIV class=plainMail>On Mon, Apr 6, 2009 at 5:06 PM, John Drescher &lt;<A href="http://us.mc320.mail.yahoo.com/mc/compose?to=drescherjm@gmail.com" ymailto="mailto:drescherjm@gmail.com">drescherjm@gmail.com</A>&gt; wrote:<BR>&gt; On Mon, Apr 6, 2009 at 4:59 PM, Jim &lt;<A href="http://us.mc320.mail.yahoo.com/mc/compose?to=jiksed@yahoo.com" ymailto="mailto:jiksed@yahoo.com">jiksed@yahoo.com</A>&gt; wrote:<BR>&gt;&gt;<BR>&gt;&gt; Dear vtkusers,<BR>&gt;&gt;<BR>&gt;&gt; While executing VTK examples such as qtevents, a black (debugging) console<BR>&gt;&gt; like Windows Command Prompt pops up. This doesn't look nice if my customers<BR>&gt;&gt; see it. How can I hide this console?<BR>&gt;&gt;<BR>&gt;&gt; #SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /subsystem:windows")<BR>&gt;&gt;<BR>&gt; Bing a windows developer for 15 years I know this should be the<BR>&gt; working one. Check your linker settings in your Visual Studio project<BR>&gt; file and make
 sure that it does say /subsystem:windows<BR>&gt;<BR>&gt; The default in cmake I believe is /subsystem:console which I know<BR>&gt; starts a new console. I remember that I used that option years ago to<BR>&gt; add debug console to all my GUI apps. :)<BR>&gt;<BR>From the cmake mailing list, I found this:<BR><BR>if(WIN32)<BR>&nbsp; &nbsp; set_target_properties(WindowApplicationExample PROPERTIES<BR>LINK_FLAGS_DEBUG "/SUBSYSTEM:CONSOLE")<BR>&nbsp; &nbsp; set_target_properties(WindowApplicationExample PROPERTIES<BR>RELWITHDEBINFO "/SUBSYSTEM:CONSOLE")<BR>&nbsp; &nbsp; set_target_properties(WindowApplicationExample PROPERTIES<BR>LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS")<BR>&nbsp; &nbsp; set_target_properties(WindowApplicationExample PROPERTIES<BR>MINSIZEREL "/SUBSYSTEM:WINDOWS")<BR>endif(WIN32)<BR><BR><BR>-- <BR>John M. Drescher<BR></DIV></BLOCKQUOTE></td></tr></table><br>