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. Control PDF from c ++

Control PDF from c ++

Scheduled Pinned Locked Moved C / C++ / MFC
question
4 Posts 4 Posters 1 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.
  • D Offline
    D Offline
    danekbb
    wrote on last edited by
    #1

    I wanted to navigate to a page in PDF file. Theoretically, this could be done with ShellExecute (NULL, "open", "Path \ File", param1, NULL, SW_NORMAL), where param1 = "# page = 123" or "/ A page = 123" or "/ A \" page = 123 \ ""; then the PDF file is opened, but the page is not activated. You could do the same thing by opening PDF and then navigating to the page. It's a good idea, but it has the disadvantage that I don't know either. Does anyone know? Thanks for the answers

    L V D 3 Replies Last reply
    0
    • D danekbb

      I wanted to navigate to a page in PDF file. Theoretically, this could be done with ShellExecute (NULL, "open", "Path \ File", param1, NULL, SW_NORMAL), where param1 = "# page = 123" or "/ A page = 123" or "/ A \" page = 123 \ ""; then the PDF file is opened, but the page is not activated. You could do the same thing by opening PDF and then navigating to the page. It's a good idea, but it has the disadvantage that I don't know either. Does anyone know? Thanks for the answers

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      It will depend on which application actually opens the PDF file.

      1 Reply Last reply
      0
      • D danekbb

        I wanted to navigate to a page in PDF file. Theoretically, this could be done with ShellExecute (NULL, "open", "Path \ File", param1, NULL, SW_NORMAL), where param1 = "# page = 123" or "/ A page = 123" or "/ A \" page = 123 \ ""; then the PDF file is opened, but the page is not activated. You could do the same thing by opening PDF and then navigating to the page. It's a good idea, but it has the disadvantage that I don't know either. Does anyone know? Thanks for the answers

        V Offline
        V Offline
        Victor Nijegorodov
        wrote on last edited by
        #3

        I posted you a working example in this post: [Control PDF from c ++](https://forums.codeguru.com/showthread.php?565583-Control-PDF-from-c&p=2239935#post2239935)

        1 Reply Last reply
        0
        • D danekbb

          I wanted to navigate to a page in PDF file. Theoretically, this could be done with ShellExecute (NULL, "open", "Path \ File", param1, NULL, SW_NORMAL), where param1 = "# page = 123" or "/ A page = 123" or "/ A \" page = 123 \ ""; then the PDF file is opened, but the page is not activated. You could do the same thing by opening PDF and then navigating to the page. It's a good idea, but it has the disadvantage that I don't know either. Does anyone know? Thanks for the answers

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #4

          You don't "control the PDF". You have to control the application that is opening and displaying the PDF file. How you do that depends entirely on the application you're using to display the PDF. There's probably going to be applications where you don't have that control. You can do it if the machine has Acrobat Reader installed it, which is what the previous answer is using.

          Asking questions is a skill CodeProject Forum Guidelines Google: C# How to debug code Seriously, go read these articles.
          Dave Kreskowiak

          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