Skip Menu |
 

This queue is for tickets about the Win32-Process CPAN distribution.

Report information
The Basics
Id: 78208
Status: resolved
Priority: 0/
Queue: Win32-Process

People
Owner: Nobody in particular
Requestors: stefanos [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.14
Fixed in: (no value)



Subject: how use with CREATE_NO_WINDOW and without in one script?
MIME-Version: 1.0
X-Mailer: MIME-tools 5.427 (Entity 5.427)
X-RT-Original-Encoding: utf-8
Content-Type: multipart/mixed; boundary="----------=_1341446567-23249-3"
Content-Length: 0
Content-Type: text/plain; charset="UTF-8"
Content-Disposition: inline
Content-Transfer-Encoding: binary
Content-Length: 215
Download (untitled) / with headers
text/plain 215b
how use with CREATE_NO_WINDOW and without in one script? Workaround with win32::gui with Win32::GUI::Hide and Win32::GUI::Show works but is not really good solution. Better solution possible? example as attachment
Subject: win32process.pl
MIME-Version: 1.0
Content-Type: application/octet-stream; name="win32process.pl"
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline; filename="win32process.pl"
Content-Transfer-Encoding: base64
Content-Length: 474
Download win32process.pl
text/x-perl 474b
#!/usr/bin/perl use Win32::Process qw(NORMAL_PRIORITY_CLASS CREATE_NO_WINDOW); Win32::Process::Create($ProcessObj, "C:\\Windows\\System32\\echo.exe", "", 0, NORMAL_PRIORITY_CLASS, "."); delete $INC{'Win32/Process.pm'};#not work? use Win32::Process qw(NORMAL_PRIORITY_CLASS CREATE_NEW_CONSOLE);# not without CREATE_NO_WINDOW ? Win32::Process::Create($ProcessObj, "C:\\Windows\\System32\\echo.exe", "", 0, NORMAL_PRIORITY_CLASS, "."); exit;
MIME-Version: 1.0
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-16822-1341472521-738.78208-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 667
Download (untitled) / with headers
text/plain 667b
You've misunderstood how CREATE_NO_WINDOW & CREATE_NEW_CONSOLE work. They're just constants that should be included as part of the $cflags (using the | operator). Simply including them as part of the import list doesn't do anything except create the constant. use Win32::Process qw(NORMAL_PRIORITY_CLASS CREATE_NO_WINDOW CREATE_NEW_CONSOLE); Win32::Process::Create($ProcessObj, "C:\\Windows\\System32\\echo.exe", "", 0, NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW, "."); Win32::Process::Create($ProcessObj, "C:\\Windows\\System32\\echo.exe", "", 0, NORMAL_PRIORITY_CLASS|CREATE_NEW_CONSOLE, ".");
MIME-Version: 1.0
In-Reply-To: <rt-3.8.HEAD-16822-1341472521-738.78208-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <rt-3.8.HEAD-16822-1341472521-738.78208-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-30732-1341681751-1940.78208-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 45
oh yes, my fault, sorry. Thanks for the help.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.