CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 1999
    Location
    India
    Posts
    14

    Shell program execution

    I'm running an exe (of a .c file) tho' my vb application using 'Shell' function provided. The exe returns exit status tho' exit statement. How can I get the status code in my vb application which has invoked the exe?
    Please help.


  2. #2
    Join Date
    May 1999
    Location
    Omika, Japan
    Posts
    729

    Re: Shell program execution

    You cannot get it using Shell.

    For this use CreateProcess api , to start the process, then if reqquired for it to finish, use WaitForSingleObject to wait till it finishes, and then use GetExitCodeProcess.

    Check on this site for sample codes. i am sure you should find some.

    RK

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured