1.GenerateConsoleCtrlEvent function Sends a specified signal to a console process group that shares the console associated with the calling process. for detail: http://msdn.microsoft.com/en-us/library/windows/desktop/ms683155(v=vs.85).aspx 2.Send sig…