begin case Message.Msg of WM_CREATEPIPE_ERROR : showmessage('创建管道错误!'); WM_CREATEPROCESS_ERROR : showmessage('创建进程错误!'); WM_READPIPE_ERROR : showmessage('读管道错误!'); WM_FINISHED_COMMAND : showmessage('命令执行完毕!'); end; inherited WndProc(Message); end; procedure TMain