Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 187399
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T15:49:00+00:00 2026-05-11T15:49:00+00:00

My question is similar to How can I programmaticly open a pdf at a

  • 0

My question is similar to ‘How can I programmaticly open a pdf at a certain point?’, but the PDF is local, not on a web server.

I need a way to jump to a given page in a PDF that is on the users computer, that works across versions of Acrobat (or using an alternative PDF viewer like Foxit Reader). The PDF is going to be called from a Java app (it is only used on Windows, so cross-platform isn’t a must), and right now it works with:

int pageNum = 24; String manualPath = 'C:\\Program Files\\Foo\\Bar\\Docs\\RefMan.pdf'; String acrordPath = 'C:\\Program Files\\Adobe\\Reader 8.0\\Reader\\AcroRd32.exe'; String cmdString = '\'' + acrordPath + \' /A \'page=' + pageNum +      '=OpenActions\' \'' + manualPath + \''; Process p = Runtime.getRuntime().exec(cmdString); 

Obviously this will only work if the end user is using Acrobat 8 for 32bit, and installed it in the default location. I next tried using:

rundll32 url.dll,FileProtocolHandler file:///C:/Program%20Files/Foo/Bar/Docs/RefMan.pdf#page=24 

thinking that this would open the users browser and jump to that page, but it simply opened Acrobat on page 1.

So I’m stumpped, and asking for help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T15:49:00+00:00Added an answer on May 11, 2026 at 3:49 pm

    I ended up implementing this by using this code to call reg.exe and parse the output from HKLM\SOFTWARE\Classes.pdf to see if its the AcroExch class, then getting the command line from HKLM\SOFTWARE\Classes\AcroExch.Document\Shell\Open\Command.

    Its hacky, but it works.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My question is similar to this one , but I can simplify it some.
I know this question is similar to several previous ones, but I can't find
I can't resolve this issue, I found a similar question here but: setting the
Maybe is a often repeated question here, but i can't find anything similar with
I feel like I've read a question similar to this but I can't find
Similar to this question but for MySQL.... How can I programmatically determine foreign key
This question is similar to How can I specifiy what access I need from
There is a similar question How can I assign the result of a subroutine
I ask a similar question here and Darin Dimitrov answer that we can't use
This is very similar to another recent question: How can I return the current

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.