Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. run an exe

run an exe

Scheduled Pinned Locked Moved C / C++ / MFC
question
7 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    radhika28
    wrote on last edited by
    #1

    I want to run an application exe from another application without control of the parent application.To be clear i am running an application from pen drive.That application in the pen drive runs another application from it.now even when i closed the parent application and i am not able to safe remove the usb dtive untill i closed the child application.Any suggestions on this?

    T D 2 Replies Last reply
    0
    • R radhika28

      I want to run an application exe from another application without control of the parent application.To be clear i am running an application from pen drive.That application in the pen drive runs another application from it.now even when i closed the parent application and i am not able to safe remove the usb dtive untill i closed the child application.Any suggestions on this?

      T Offline
      T Offline
      toxcct
      wrote on last edited by
      #2

      ::ShellExecute(NULL, _T("C:\\folder\\myprog.exe"), NULL, NULL, NULL, SW_SHOWNORMAL);


      [VisualCalc][Flags Beginner's Guide] | [Forums Guidelines][My Best Advice]

      R 1 Reply Last reply
      0
      • T toxcct

        ::ShellExecute(NULL, _T("C:\\folder\\myprog.exe"), NULL, NULL, NULL, SW_SHOWNORMAL);


        [VisualCalc][Flags Beginner's Guide] | [Forums Guidelines][My Best Advice]

        R Offline
        R Offline
        radhika28
        wrote on last edited by
        #3

        hi thanks for your reply.I have one question is this function run without the control of the parent application(from which we run this). Thanks

        T 1 Reply Last reply
        0
        • R radhika28

          hi thanks for your reply.I have one question is this function run without the control of the parent application(from which we run this). Thanks

          T Offline
          T Offline
          toxcct
          wrote on last edited by
          #4

          yes, ShellExecute() is the API called when you double click on the icon of a programme to start it. when doing so, is your program dependant of explorer.exe ? no.


          [VisualCalc][Flags Beginner's Guide] | [Forums Guidelines][My Best Advice]

          R 1 Reply Last reply
          0
          • T toxcct

            yes, ShellExecute() is the API called when you double click on the icon of a programme to start it. when doing so, is your program dependant of explorer.exe ? no.


            [VisualCalc][Flags Beginner's Guide] | [Forums Guidelines][My Best Advice]

            R Offline
            R Offline
            radhika28
            wrote on last edited by
            #5

            ya.My problem is when i used this function to run an exe from an application running in usb drive.Now when i closed the application in the usb drive,the usb is not safe removed untill i close the exe which i runned using shellexecute function.How can i resolve this?

            D 1 Reply Last reply
            0
            • R radhika28

              I want to run an application exe from another application without control of the parent application.To be clear i am running an application from pen drive.That application in the pen drive runs another application from it.now even when i closed the parent application and i am not able to safe remove the usb dtive untill i closed the child application.Any suggestions on this?

              D Offline
              D Offline
              David Crow
              wrote on last edited by
              #6

              radhika28 wrote:

              I want to run an application exe from another application without control of the parent application.

              Check this out.


              "Approved Workmen Are Not Ashamed" - 2 Timothy 2:15

              "Judge not by the eye but by the heart." - Native American Proverb

              1 Reply Last reply
              0
              • R radhika28

                ya.My problem is when i used this function to run an exe from an application running in usb drive.Now when i closed the application in the usb drive,the usb is not safe removed untill i close the exe which i runned using shellexecute function.How can i resolve this?

                D Offline
                D Offline
                David Crow
                wrote on last edited by
                #7

                radhika28 wrote:

                How can i resolve this?

                Well, technically the drive is in use. See if this is of any help.


                "Approved Workmen Are Not Ashamed" - 2 Timothy 2:15

                "Judge not by the eye but by the heart." - Native American Proverb

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups