Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Open Pdf Within Qt application and go to specific page.
Forum Updated to NodeBB v4.3 + New Features

Open Pdf Within Qt application and go to specific page.

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 1.1k 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.
  • S Offline
    S Offline
    Sebastian
    wrote on last edited by
    #1

    I have spent couple of days to search my answer but not lucky to get the answer.so i need help to all my friends.

    Within my Qt application I'm able to open a PDF using the OS default viewer thru the following code:

      QDesktopServices::openUrl(QUrl::fromLocalFile(filePath));
    

    This works fine.but now i want the functionality like if i want to directly go to specific page eg page number 20 so we can directly go to that page.
    So basicly i want a function in my class where we can specify the page number of pdf file and directly jump to that page number.

    thanks for help in advance

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      I dont think u can as you just tell system,
      "please open what ever application that like this file."

      It also depends on viewer how to go to a page.,

      For Acrobat reader, it takes
      Acrobat /A "page=<pagenum>" %1.pdf

      /A command line to open at a page but for other viewers it will be different.
      http://partners.adobe.com/public/developer/en/acrobat/PDFOpenParameters.pdf

      1 Reply Last reply
      1

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved