Open a random PDF document using Javascript

Hello

I am creating a button in my XDP form that will work as a link 'Open Page' standard in a PDF file.  I want to be able to define the path of the file and the number of page of a PDF document and open the document in a new window to this page.

The target documents are provided by a third party and I don't have the ability to dictate to format or anything else.

Any ideas?

I found the answer.  radzmar was partially right.  It was used app.openDoc but necessary for a function of confidence and an additional command:

myDoc var = app.openDoc (path);

mydoc.pageNum = page;

Tags: Adobe LiveCycle

Similar Questions

  • I want to open two different pdf documents and view them at the same time so I can read about everything by watching the other document.  I use Acrobat DC and whenever I open a document it creates a tab and I can only examine a document at a time.

    I want to open two different pdf documents and view them at the same time so I can read a whole watching the other document.  I use Acrobat DC and whenever I open a document, it creates a tab and I can only examine a document at a time. Is it possible to display two or more documents without having to toggle tabs?

    Don't think that will work, but you can drag the tab to a new window. Each window can have a set of tabs.

  • Can I print the last page of a PDF document using the command line?

    Hello

    I'm in a situation where I constantly have to deal with several documents in PDF format, and I need to print the last page in each of them and ONLY the last page. The total number of pages vary for each file, so the page to the last page number will also vary.

    I really prefer to not do it manually, to open each file in the visible window of Adobe Reader, and then print.

    Question:

    Is it possible with Adobe Reader (perhaps with the help of another Adobe product) to print only the last page of a PDF document using some sort of command line without having to open the PDF file in the Adobe Reader window visible?

    I use Windows.

    Thanks in advance,

    Kind regards

    Emil

    Hey, I've just set up a measure of inquiry by accident. That's really bad thinking. Here's what to do.

    When the "Create new Action" checkbox is shown...

    Choose Start with: a file open in Acrobat

    DO NOT CLICK on add a step statement

    Open tools more

    Click once on run JavaScript

    A blue line to run JavaScript must appear on the right side.

    Click on the small box under Options inside the blue line

    A JavaScript editor should appear; Enter the program, and then click Ok

    To save in: select do not save the changes.

    Click Save

    Give a name; you don't need to enter a description (although it won't hurt if you do).

  • Unable to view PDF documents using Adobe Acrobat Reader DC

    Hello

    Recently, I have been unable to open PDF documents using this program - up to this point I use it regularly with several of the same PDF files and none of the files opened.

    When I open the file of Evernote, it seems to work fine, RCAA opens but the file does not appear, if I right click and select "Show all windows" the name of the file in question appears on the screen Screen Shot 2016-07-07 at 09.03.51.png .

    I have taken steps to update the program and I have installed and reinstalled, but the problem persists.

    I also downloaded another PDF reader and the file opens correctly in the program.

    I use a Macbook Air running OS X EI captain, version 10.11.5.

    Any help would be appreciated.

    Best regards

    Ryan

    I've seen the suggestion to try the tile in the window menu. Does that help?

  • I recently tried to open a new pdf file using an existing program Acrobat Reader and it changed the extensions of all programs and .pdf desktop icons, making them unusable.  I uninstalled Reader and extensions have been fixed.  But when I installed the dr

    I recently tried to open a new pdf file using an existing program Acrobat Reader and it changed the extensions of all programs and .pdf desktop icons, making them unusable.  I uninstalled Reader and extensions have been fixed.  But when I installed the drive again - the latest version (DC) it happened again.  How can I fix it?  I am on Windows 7

    Hi donaldm78047015,

    Try the solution mentioned in this KB doc. https://helpx.Adobe.com/Acrobat/KB/application-file-icons-change-Acrobat.html

    Kind regards

    Nicos

  • I'm having a problem at the opening of the pdf document.  I get the error message: 'Adobe Reader has stopped working ".

    I'm having a problem at the opening of the pdf document.  I get the error message: "Adobe Reader has stopped working" then I get Windows to search online for a solution, but then my document is closed. I tried to uninstall and reinstall Adobe Reader XI, restarted my computer, but it did not help.  I get the same message. What should do?

    Can you open Reader by itself?  If so, check that disable the Protected Mode improves the situation [Edit |] Preferences | (Improved) security].

  • Problem to open a single Pdf document of 250 MB

    My customer sent me a single PDF document that is 250 MB. By the time I opened the document ITI meets maybe more because of its huge size. Any suggestions to solve the problem? Can I send it to you by an e-mail link to see the problem. Thanks in advance.

    Hi Ana Maria,

    I managed to solve the problem today by dividing it into smaller documents using the pdfill Editor.

    Thank you

    Concerning

    Alaa

  • DeskJet 1510 while a single printe: can the deskjet printer 1510 create a searchable pdf document using acrobat reader dc?

    When scanning documents using the HP 1510, I already had a drop down menu the possibility to save my document in pdf format 'searchable' that I use to run another program that combines my PDFs in a large document.  Then my computer crashed during installation windows 10 and I lost everything.  I returned to windows printer drivers 7 resettled the 1510 and all software on the HP site and installed acrobat reader dc as my adobe product.  Now when I scan everything I see is to scan in pdf format.  How can I return the option scan to searchable PDF?

    Hello

    You can check the 3rd aprty following software that analyzes the text of a PDF scanning serchable:

    https://www.naps2.com/

    For the recognision of handwritten text, you need to get a professional OCR software, such will probably cost... I'm not aware of any freeware OCR program which is capable of such a...

  • How to make a selection in a drop-down list to open a specific pdf document?

    I have a form with several falling to the low fields. I would like to have every support on the selection of a specific existing pdf document, based on the selected item. Any help would be appreciated!

    Thank you

    Corky

    As the custom field validation script, you can use something like this (of course, adjust the values and the paths of files to match those you want, but retain the syntax of path - as I've used):

    if (event.value=="Option 1") this.openDoc("/c/files/option1.pdf");
    else if (event.value=="Option 2") this.openDoc("/c/files/option2.pdf");
    else if (event.value=="Option 3") this.openDoc("/d/temp/option3.pdf");
    // etc.
    

    Make sure that check the option to validate the selected value immediately (under properties of the field - Options) to be run as soon as a selection is made.

  • How can I change the text in a pdf document using an embedded font?

    I'm trying to edit text in a pdf document where the text is in a (Nimbus San) embedded font, but when I try to add some text in the text box, it appears in Minion instead of the police of San Nimbus.  I don't understand why I can't change by using the embedded font.

    The fonts are licensed assets subject to single use. They are not intended to share, redesigned, etc..

    As part of the PDF standard that they included in a document so that the document can be considered reliably without the police be installed on the viewing station.

    To change you must have fonts installed on your computer. The possibility for the second parties to use the police violate the licensing of fonts.

  • How 2 search within a PDF document using the PDF reader internal Firefox

    Could not find a way to search for text in a PDF document, when it is displayed by the PDF reader integrated into Firefox.

    If there is a way, how do you?

    If there isn't a way, it seems an obvious improvement.

    Implementation of the "Find" (CTRL + F) feature usual should work within a PDF in Firefox.

  • Avoid the news since Acrobat messages when it is opened to broken PDF document

    I use Adobe SDK to check and fix a bunch of PDF files

    Dim avDoc As AcroAVDoc = Nothing
        Dim pdDoc As CAcroPDDoc = Nothing
        Try
            avDoc = New AcroAVDoc()
            If (avDoc.Open(sourceFile.FullName, String.Empty)) Then
                pdDoc = avDoc.GetPDDoc()
                RemoveIfExists(destinationFile)
                CreateIfNotExits(New DirectoryInfo(destinationFile.DirectoryName))
                pdDoc.Save(3, destinationFile.FullName)
                pdDoc.Close()
                avDoc.Close(1)
                Return True
            End If
            Return False
        Catch generatedExceptionName As Exception
            Me.logger.Error(String.Format("Error while converting {0} to {1}. The error message: {2}", sourceFile.FullName, destinationFile.FullName, generatedExceptionName.Message))
            Me.logger.Fatal(generatedExceptionName.StackTrace)
            Return False
        Finally
            If (avDoc IsNot Nothing) Then
                avDoc.Close(1)
            End If
            If (pdDoc IsNot Nothing) Then
                pdDoc.Close()
            End If
        End Try

    But when I try to open the PDF file that cannot be opened for any reason, the information message

    Capture.PNG

    How to avoid this?

    Open the document as a PDDoc first, then convert to an AVDoc. Use an error

    Manager to trap the error that is thrown by the Open when call the file

    cannot be opened.

    pdDoc.Open("c:\test\dummy.pdf")

    pdDoc.OpenAVDoc (' ')

    Karl Heinz Kremer

    PDF acrobatics without a net

    PDF, training software development and much more...

    [email protected]

    http://www.khkonsulting.com

  • Remove the Script level Document using JavaScript?

    Hi all.

    Is it possible for a document-level script to delete itself? I am running Adobe Acrobat Professional 11.

    My situation is that I'm currently analysis data using a Java application. The taylors Java application a script based on each specific PDF and then inserts it into the PDF file automatically. When the PDF file is opened, the script runs once and then is no longer necessary.

    Because the script is no longer required, it would be preferable if the script could be deleted automatically. Is it possible that the script has access to the field in which it is stored (for example, doc.javascriptField = "" ;)?) Or by some miracle, a remove function already exists?

    I think that the lack of need for such function by General and advanced users I won't get it the answer I hope. But it's worth a shot. Meanwhile, I am inserting a flag in the field keyword so that the script does not run twice. It works, but it is not really clean.

    Any help would be greatly appreciated.

    Thank you

    Jonny O

    Use this code:

    this.removeScript ("ScriptName");

  • How to OPEN and read pdf documents online rather than download, save and then read and delete. This only happens on some sites & started recently.

    When I go on a website and try to open something (like a monthly statement of account, etc.) instead of opening it as a pdf so I can read Firefox makes me download it, save it and then open it. Then I have to go find and remove routine if I don't want to keep. Don't know why this started happening recently, and he disobeys on all sites.

    Please, try the following:

    1. Open the Firefox Options window
    2. Select the Applications tab
    3. Locate Portable Document Format (PDF) on the list of file types
    4. Change the Action Preview in Firefox
    5. Click Ok

    This should allow you to get an overview of most of the files in Firefox.

    It will not work in all cases because some site contain codes to force the browser to download instead of the preview.

  • Place an SVG in a document using Javascript (Extendscript) illustrator

    Hello

    I'm trying to place an svg in illustrator with extendscript. Here is basically what I do

    var doc = app.documents.add(); var p = doc.placedItems.add(); p.file = new File(svgfilepath); 

    This operation fails with the error

    File is in a format that cannot be placed

    I am able to put the same file manually using file > Place. Am I missing something? Need help!

    [Link SO]

    Hi, try the following:

    // Reference: https://forums.adobe.com/thread/1722322
    //
    // Assumes you have an open Illustrator document
    // and an SVG file on your desktop named: testSVG.svg
    //
    // Basic Example:
    // Tested and worked in Illustrator CS5 / OS X
    //
    var doc = app.activeDocument;
    var svgFile = File(Folder.desktop + '/testSVG.svg');
    doc.groupItems.createFromFile(svgFile);
    

    Jongware say hello 'SO', and that it was right on the team of JS Illustrator. ;-) Also for later use, we have an Illustrator Scripting forum here.

Maybe you are looking for

  • I lost the search function of the messages and the folder "sent" under my second email address.

    The search function to search for messages that were sent to me has disappeared. I also have to email addresses in thunderbird. One shows all my sent messages. But there is no option "sent" under my second email address

  • Error keyboard satellite 4090 xcdt

    I installed winxp home on mij satellite, it works (slow but works).Since a few days I had problems with keyboard mij.When I press left SHIFT I get Windows XP help screen. The left alt is given too many strange things.So I can not use capitals because

  • Crackling while playing music in the SPECTRUM of the HP 15 - 4010nr Ultrabook

    Hi all I recently bought [4 January 2013 ] 15-4010nr SPECTRUM HP Touchsmart ultrabook with beats audio. I'm very unhappy with the Crackle of the bursts of noise while playing music sudden or random. The problem is not limited to pregnant hp integrate

  • Lenovo ThinkPad X 201 white screen

    Hello My laptop screen has turned white and nothing is displayed. It works perfectly fine with an external monitor. Could it be inverter or I need to replace the screen? Thanks in advance.

  • Y510p boot from USB

    If my hard drive is dead and I replaced it. Now, I came to the conclusion that my Windows 8 product key is encrypted in the BIOS, so all I need to do is to use the recovery to do a clean install. But given that the laptop came with installed I have n