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. Handling shell command line

Handling shell command line

Scheduled Pinned Locked Moved C / C++ / MFC
linuxtutorialquestion
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.
  • U Offline
    U Offline
    User 2299399
    wrote on last edited by
    #1

    Hello, I would like that users be able to launch my application from the Shell "Open with" menu. Can somebody explain how to achieve that? Thanks

    D 1 Reply Last reply
    0
    • U User 2299399

      Hello, I would like that users be able to launch my application from the Shell "Open with" menu. Can somebody explain how to achieve that? Thanks

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

      See here.


      "Take only what you need and leave the land as you found it." - Native American Proverb

      A 3 Replies Last reply
      0
      • D David Crow

        See here.


        "Take only what you need and leave the land as you found it." - Native American Proverb

        A Offline
        A Offline
        Allad
        wrote on last edited by
        #3

        Hello, Thank you for replying. I followed your link. But I've already call EnableShellOpen in the CWinApp::InitInstance. And my application is listed under "Open with" menu. When I open a file with the "Open with" menu, the shell actually launch my app. However I don't know how to do further processing like retrieving the file being launched and open it. Can you help me doing that?

        D 1 Reply Last reply
        0
        • D David Crow

          See here.


          "Take only what you need and leave the land as you found it." - Native American Proverb

          A Offline
          A Offline
          Allad
          wrote on last edited by
          #4

          Hello, Thank you for replying. I followed your link. But I've already call EnableShellOpen in the CWinApp::InitInstance. And my application is listed under "Open with" menu. When I open a file with the "Open with" menu, the shell actually launch my app. However I don't know how to do further processing like retrieving the file being launched and open it. Can you help me doing that?

          1 Reply Last reply
          0
          • D David Crow

            See here.


            "Take only what you need and leave the land as you found it." - Native American Proverb

            A Offline
            A Offline
            Allad
            wrote on last edited by
            #5

            Hello, Thank you for replying. I followed your link. But I've already call EnableShellOpen in the CWinApp::InitInstance. And my application is listed under "Open with" menu. When I open a file with the "Open with" menu, the shell actually launch my app. However I don't know how to do further processing like retrieving the file being launched and open it. Can you help me doing that?

            1 Reply Last reply
            0
            • A Allad

              Hello, Thank you for replying. I followed your link. But I've already call EnableShellOpen in the CWinApp::InitInstance. And my application is listed under "Open with" menu. When I open a file with the "Open with" menu, the shell actually launch my app. However I don't know how to do further processing like retrieving the file being launched and open it. Can you help me doing that?

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

              Allad wrote:

              However I don't know how to do further processing like retrieving the file being launched and open it.

              I'm assuming you have either an SDI or MDI application. Yes? If clicking on a particular file opened your application, then the file is already opened and its name can be obtained from the document's GetPathName() method.


              "Take only what you need and leave the land as you found it." - Native American Proverb

              A 1 Reply Last reply
              0
              • D David Crow

                Allad wrote:

                However I don't know how to do further processing like retrieving the file being launched and open it.

                I'm assuming you have either an SDI or MDI application. Yes? If clicking on a particular file opened your application, then the file is already opened and its name can be obtained from the document's GetPathName() method.


                "Take only what you need and leave the land as you found it." - Native American Proverb

                A Offline
                A Offline
                Allad
                wrote on last edited by
                #7

                Thank's. It works.

                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