Re: bug in GenerateConsoleCtrlEvent?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Gary Chanson (gchanson_at_No.Spam.TheWorld.net)
Date: 07/31/04


Date: Sat, 31 Jul 2004 12:22:40 -0400


"Sam Jost" <samjost@web.de> wrote in message
news:6696c336.0407310312.444d78fd@posting.google.com...
> "Sam Jost" <lumica@noemail.nospam> wrote:
> > I'm trying to end a process by sending him ctrl+break with
> > GenerateConsoleCtrlEvent.
>
> Ah well, I did a few days of digging into this matter, and since the
> only way to send a ctrl+c or ctrl+break to a console app would kill
> the sending app too I just start a new process to attach to the
> console one that'll kill both by sending ctrl+c to it. So my main app
> did not need to do the dirty work of killing the sub app, and
> everyone's getting a friendly end.

    It's only a close event which forces the application to end.

-- 
-GJC [MS Windows SDK MVP]
-Software Consultant (Embedded systems and Real Time Controls)
- http://www.mvps.org/ArcaneIncantations/consulting.htm
-gchanson@mvps.org


Relevant Pages

  • Re: bug in GenerateConsoleCtrlEvent?
    ... >> the sending app too I just start a new process to attach to the ... You kill zip.exe it will leave a temporary file behind. ... If you have a better way to end a console app without resorting to Kill() ...
    (microsoft.public.win32.programmer.kernel)
  • Re: simple TCP/IP messaging
    ... I use the MSWinsock control, ... > Does anyone know of an easy to use TCP/IP messaging library. ... > Sending / Client App ... > For my application I only need communication from the Sending App to the ...
    (microsoft.public.fox.programmer.exchange)
  • Re: MSMQ
    ... I have both 1.1 and 2.0 runing. ... I have writen the app in vb.net 2003 and 2005 and get the same error. ... mmm I just copied the app to a new server (sending app) and it ... network share? ...
    (microsoft.public.dotnet.languages.vb)
  • RE: SHA-based subclass for random module
    ... Yes, but different RNGs have different weaknesses, and whether the ... If you need to generate "random" points in 3D space, does it matter that the ... if your app relies on the triples ... distribution in 3D space. ...
    (comp.lang.python)
  • Re: Tkinter or wxpython?
    ... mean by a "good reason" to write a desktop gui. ... Might or might not matter depending on the application. ... Compared to a desktop app? ...
    (comp.lang.python)