Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re^2: Kill a perl script execution in windows

by BrowserUk (Pope)
on Feb 18, 2013 at 13:44 UTC ( #1019342=note: print w/replies, xml ) Need Help??

in reply to Re: Kill a perl script execution in windows
in thread Kill a perl script execution in windows

That's good for preventing a second copy from starting; but not so useful for killing the previous version if it is running because it doesn't give you the pid.

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
  • Comment on Re^2: Kill a perl script execution in windows

Replies are listed 'Best First'.
Re^3: Kill a perl script execution in windows
by nikosv (Chaplain) on Feb 18, 2013 at 16:06 UTC
    you don't need the PID. The first script waits for a signal to terminate as:
    use Win32::Event; use 5.010; $event = Win32::Event->new(1,0,"myevent"); while ($event->wait(0)==0) { say $i; print $i++; } say "exiting";
    or just $event->wait(), depends on the situation.Then the second one can signal it to abort :
    use Win32::Event; use 5.010; $event = Win32::Event->new(1,0,"myevent"); say $^E; $event->set;

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1019342]
[1nickt]: Corion HPs? ugh. I was impressed with Lenovo's gaming laptops; if it weren't for the red backlighting and general flashiness of the aesthetic, I might have gone with that. But all that was until I discovered that the Dell Precision line is still around.
[1nickt]: stevieb I don;t doubt that there's a difference. BestBuy has "consumer" models only on display.
[ambrus]: 1nickt: for some reason, these days they call every computer "gaming", even ones that gamers wouldn't buy. I've bought a keyboard that was labelled "gamer", despite that it has hard springs and seems to be way better for typing than for gaming;
[1nickt]: I though the gamers like that because they bash the keys so hard.
[ambrus]: and I've seen motherboards with no fast expansion ports for a video card but built-in hardware RAID advertized as "gaming".
LanX has a shaming laptop
[ambrus]: 1nickt: my impression is that the gamers like the softer springs, because fast reaction time is more important to them then feedback from keypresses to recognize typos.
[1nickt]: Ah, I see. I did read some gamer mag reviews, and yes, they lamented the fact that laptops with no discrete video card are sold as "gaming" hardware.

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (14)
As of 2017-03-27 13:41 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (320 votes). Check out past polls.