Beefy Boxes and Bandwidth Generously Provided by pair Networks Joe
There's more than one way to do things
 
PerlMonks  

Re: Re: background Win32 process'

by sevensven (Pilgrim)
on Oct 24, 2001 at 15:40 UTC ( [id://121150]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re: background Win32 process'
in thread background Win32 process'

You will need to use a flag that I dont see documented in Win32::Process, but that is in the first page of Process.pm (DETACHED_PROCESS).

I hope the folowing code borrowed from Dave Roth's Win32 Perl Programming helps :

use Win32::Process; # Win32::Process::Create( $process, $program, $command_line, $inherit, + $flags, $directory) $app = "d:\\apps\\perl\\bin\\perl.exe"; $cmd = 'perl daemon.pl'; $b_inherit = 1; $flags = CREATE_NEW_PROCESS || DETACHED_PROCESS; $dir = '.'; $result; $result = Win32::Process::Create( $process, $app, $cmd, $b_inherit, $flags, $dir); if ($result) { print "$cmd has been created with process id of $result\n"; } else { print "unable to start $cmd\n"; print "error : " . Win32::FormatMessage( Win32::GetLastError() ); }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://121150]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.