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
    Posts
    170

    Starting new process

    How to start new process(like Notepad) in my MFC based project?

    Thanks, Honza


  2. #2
    Join Date
    Sep 1999
    Location
    Europe / Austria / Innsbruck
    Posts
    442

    Re: Starting new process

    Hi, try this:

    PROCESS_INFORMATION info;
    STARTUPINFO startup;
    CString strExePath = "notepad.exe";

    memset(&startup, 0, sizeof(startup));
    startup.cb = sizeof(startup);

    if(CreateProcess(NULL, strExePath, NULL, NULL, FALSE, 0, NULL, NULL, &startup, &info))
    {
    // notepad started
    }





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