Scripting help for image pop-up within a PDF

Hi,
I'm creating some sample eBooks in Acrobat Professional 9 (Mac), and I am stuck on one element that needs to be present. In the text within the PDF, there might be a phrase like, "See Fig. 1". Fig. 1 might not be on that page, however. I know how to create a link in a PDF that will navigate the reader to the page with the image referenced, but that's not good enough. I'd like to have this happen:
User clicks on "See Fig. 1".
Popup window appears with the referenced thumbnail image.
The image's popup window will stay on-screen until dismissed by the user.
Clicking on the popup thumbnail image calls up a full-size image.
The added wrinkles are many after we figure out the scripting for the above, but here are two major ones to be addressed right away:
1) The images are already part of the typeset document converted to PDF, so I am guessing the images would have to be bundled with the PDF somehow. Our users need to use the PDFs in an offline environment, so a call-out to a URL is out of the question.
2) The PDFs will be read on Macs, PCs, and possibly iPads. If a bundled, local file is called out when a user clicks on "See Fig. 1", how do I set a relative filepath in the call-out?
Thanks for any help you can provide.
Andrew

Here's a sample document that demonstrates some of what you're asking about: https://acrobat.com/#d=aP-2xL45pM57xVkT6d6fSg
The images are stored in buttons, so there is no concern about having to use external images. Note that this may not work on an iPad since most (all?) PDF viewers on the iPad do not have JavaScript support.

Similar Messages

  • Help for image pattern matching

    Hello Everyone
    I am working for my last year project. In my project I will work on the image processing to find a moving object. I will work by JMF. I have finished to grab a frame from the webcam video clips. Now I need a algorithm to find a Image pattern from the grabed image. But I donot know which algorithm is fine for image pattern matching as well as how can I implement in java. Is anyone know please help me very urgently.
    Thank you
    Md. Mainul Hasan

    If you would like to take a look at http://www.exactfutures.com/index01.htm and http://www.exactfutures.com/index02.htm and http://www.codeproject.com/useritems/activity.asp then these pages and links may well be useful to you. It may not be exactly what you are looking for, but it does point to some examples with source for video analytics, and at the very least they illustrate how to capture & handle the data including a fast movement detection algorithm. If you want to find a specific shape then search the internet for information on chamfer distance transforms - one can use JMF or extend these simple examples to apply those techniques.

  • Startup shell script help for newbie?

    New to UNIX (linux)... need the bash shell script commands for my r.c local file to start my services when server boots.
    I got my ds, dps and admin server in their respective /opt directories. I need the shell commands to have these start. Of course I can start them manually but when I try a line like this in a script, it doesnt work:
    ./var/opt/sun/directory-server/slapd-dsserver/start-dsserver
    Some path problem or dot thing?

    There are a few other things you may want to consider, such as what the default browser is, are tabs being used, is the page loaded yet, etc, but Safari has a do javascript command in it's scripting dictionary. The following script will open a new document and run your specified javascript, or you can go to their NPR Program Stream Page and download a playlist that will run directly from iTunes.
    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px; height: 335px;
    color: #000000;
    background-color: #FFDDFF;
    overflow: auto;"
    title="this text can be pasted into the Script Editor">
    set my_script to "NPR.Player.openPlayer(2, 0, '03-21-2008', NPR.Player.Action.PLAY_NOW, NPR.Player.Type.PROGRAM, NPR.Player.Mode.LIVE)"
    tell application "Safari"
    activate
    set the URL of the front document to "http://www.npr.org/"
    if my page_loaded(20) is false then error numner - 128 -- page not loaded in time
    do JavaScript my_script in document 1
    end tell
    on page_loaded(timeout_value) -- from http://www.apple.com/applescript/archive/safari/jscript.01.html
    delay 2
    repeat with i from 1 to the timeout_value
    tell application "Safari"
    if (do JavaScript "document.readyState" in document 1) is "complete" then
    return true
    else if i is the timeout_value then
    return false
    else
    delay 1
    end if
    end tell
    end repeat
    return false
    end page_loaded
    </pre>

  • Script Help for iPhoto

    fairly new to Mac. I life iPhot....except, when I mod a photo, it moves to a completely different folder. My simple mind can't grasp the fundamentals of either applescript or automator. Can someone help me write a script that will help move the modified photo's from the iphoto library's "modified" folder, back to the original folder?
    Mahalo,
    Mike

    You can drag and drop the image from iPhoto to wherever you need it. For example, just drag and drop an image from iPhoto to the Desktop, and then you have a copy on the Desktop. If you don't want it in iPhoto anymore, just delete within iPhoto and the original and any modifications are gone. You'll also find buttons in iPhoto that let you easily set your Desktop background, send photos in an email, or publish them with iWeb, among other things.
    iPhoto is for not having to worry about where or how your photos are organized on the your hard drive, just like iTunes does for music. Just let iPhoto handle the organization. Free your mind, let your computer do the work. This is the 21st century, you know.
    Also consider creating albums in iPhoto for your own grouping, and tagging images with keywords and comments so you can create smart albums to automatically do the grouping for you. You can also drag and drop an image from one film roll to another or combine film rolls. Time to let go of the Finder when it comes to organizing your images.

  • Scripting help for a tedious process.

    Ian Wood wrote a script that takes a list of version names from a Word.doc or plain text doc. and opens Aperture, searches the Library and then creates an album from those gathered images. This is great, for example if a Bride gives you a list of her favorite photos for the design of the final wedding book.
    The script works well, however it looks at the whole Aperture library.
    If you have versions with the same name it only picks one.
    (You may have exactly the same version names scattered around your library because your camera cycles back to 0001 after it reaches 9999)
    If someone out there knows how to re-write the script so that it only looks in a particular project as it picks the version names, then an otherwise tedious process would be simplified.
    Any help would be appreciated.
    The following is a copy of Ian's script.
    This script is written by Ian Wood. No warranty is given or implied for the script's use.
    Feel free to copy and adapt this script for your own use. Originally written in answer to a thread on the Aperture discussion forum.
    Please visit http://www.aperture-assistant.com for more scripts and information about automation and Aperture.
    set tfile to (choose file "Pick the text file")
    set fref to (open for access tfile) -- now we read the file in
    set tSize to (get eof tfile)
    set tText to (read fref as string from 1 to tSize)
    close access fref
    log tText
    set tList to every paragraph of tText -- turn the lines into a list
    tell application "Aperture"
    activate
    tell library 1
    set this_project to make new album with properties {name:"Results of file name list"} -- you can change this if you want the Album to have another name.
    end tell
    repeat with i from 1 to the count of the tList
    set tName to item i of the tList
    set tImgID to "not found"
    try
    set tImgID to (first image version whose name is tName)
    end try
    if tImgID is not "not found" then
    try
    duplicate tImgID to this_project
    end try
    else
    log tName
    end if
    end repeat
    end tell

    Ian Wood wrote a script that takes a list of version names from a Word.doc or plain text doc. and opens Aperture, searches the Library and then creates an album from those gathered images. This is great, for example if a Bride gives you a list of her favorite photos for the design of the final wedding book.
    The script works well, however it looks at the whole Aperture library.
    If you have versions with the same name it only picks one.
    (You may have exactly the same version names scattered around your library because your camera cycles back to 0001 after it reaches 9999)
    If someone out there knows how to re-write the script so that it only looks in a particular project as it picks the version names, then an otherwise tedious process would be simplified.
    Any help would be appreciated.
    The following is a copy of Ian's script.
    This script is written by Ian Wood. No warranty is given or implied for the script's use.
    Feel free to copy and adapt this script for your own use. Originally written in answer to a thread on the Aperture discussion forum.
    Please visit http://www.aperture-assistant.com for more scripts and information about automation and Aperture.
    set tfile to (choose file "Pick the text file")
    set fref to (open for access tfile) -- now we read the file in
    set tSize to (get eof tfile)
    set tText to (read fref as string from 1 to tSize)
    close access fref
    log tText
    set tList to every paragraph of tText -- turn the lines into a list
    tell application "Aperture"
    activate
    tell library 1
    set this_project to make new album with properties {name:"Results of file name list"} -- you can change this if you want the Album to have another name.
    end tell
    repeat with i from 1 to the count of the tList
    set tName to item i of the tList
    set tImgID to "not found"
    try
    set tImgID to (first image version whose name is tName)
    end try
    if tImgID is not "not found" then
    try
    duplicate tImgID to this_project
    end try
    else
    log tName
    end if
    end repeat
    end tell

  • Adobe Forms - FormCalc Scripting Question for Image Control

    Hi All,
    I have three images on my master page. I have a hidden text field. Based on a certain value within this text field I need to turn off Imagefield B and ImageField C and Leave ImageField A visible.
    I know this can be done via FormCalc scripting.
    My Questions:
    Which event shoudl I put the script in? I was thinking the textfield initialize event.
    What would be the EXACT syntax to turn turn image fields on or off?
    Please inform if know.
    Regards,
    Salil

    I solved it now, just changing the FormCalc expression.
    Instead of using the expression:
    this.value.image.href = xfa.resolveNode(this.value.image.href).value;
    I used this:
    this.value.image.href = xfa.record.Images.URL;
    The URL value of Image Field, in this case is:
    <b>$record.Images[*].URL</b>
    And, to finish, I needed to add a Text Field bounded to  <b>$record.Imagens[*].URL</b>, case else the image doesn't appear.
    That's it!

  • Help for Image detection in video & hardware issues

    Hi,
    I am trying to develop a web app that lets the user select shapes in a video(user can click only on detected shape if clicked elsewhere it should inform user to click only on the detected shape)
    Then the location of the clicked position is determined & a robotic arm(at remote location) is moved to that position
    I am a newbie on JMF
    I do have a solution: load video on an applet(which can help in determining location of click but how would it know that the clicked position has the detected shape or not)
    And here are my questions:
    Is solution right?
    Are there other solutions that i miss up?
    What is the best language for hardware (microcontroller) programming here?
    Is interaction between JMF & remote hardware possible & how?
    Thank u all in advance

    saurabh.nigam wrote:
    Is solution right?The thing you're calling a "solution" doesn't appear to be a solution. Normally, solutions don't have questions embedded in them...
    Are there other solutions that i miss up?Again, you're not being clear and you're nowhere near a solution...
    What is the best language for hardware (microcontroller) programming here?That's not a question for this forum. This forum is for questions about the JMF API...
    Is interaction between JMF & remote hardware possible & how?Yeah, you can always send commands via a socket using normal Java stuff. JMF isn't a special langauge or anything, it's just some Java classes that do media stuff...
    In order to do what you're wanting to do, you'd have to implement a series of "not easy" things to implement.
    1) You'd need to implement some sort of blob detection / extraction code that would take in an image and detect / extract the blobs in it.
    2) You'd need to implement some sort of blob shape filter that would filter out all of the detected blobs that aren't a shape you're happy with
    3) You'd need to embed your blob code into a JMF effect class so it could process video frames as they come through
    4) You'd probably also want to augment the video stream with outlines or translucent colored regions to indicate to the user where the clickable blobs are...
    5) You'd need to implement a socket-based control protocol for controlling the remote hardware.
    All of that is possible with Java / JMF, but none of it is easy.

  • Need Help for Image Processing

    Hi everyone,
    my name is Davide and I am a new member. I apologize in advance for my English that It's not very good.
    I have to do an exercise where I have to draw a SAR(Synthetic Aperture Radar) Image. The problem is that the input image is composed by a binary raster plus an XML parameters file. The XML file contains all the information to correctly read the image.
    I downloaded Java Advancing Imaging Library but I've never worked with this image format and I don't know where to start.
    Can anyone help me? How should i do with the binary raster file? How can i read it?
    Thank you very much.

    Hi everyone again,
    I followed your advice and I studied the theory on raster data so I have made some step forward. Now I have a new problem that I will try to explain you in the better way. I was able to obtain from the binary raster data an array of float.
    From the XML parameters file I know that the rows number are 1000, the columns number are 2000, the pixel type is complex float and that the real and imaginary parts are put side-by-side on a column basis. I created two array, one of the real parts and one of the imaginary parts:
    for (int i=0;i < SIZE_X*SIZE_Y; i++){
       if(i%2 == 0){
          real[k] = bin_input;
    if(Math.abs(real[k]) > max_value_re){
    max_value_re = Math.abs(real[k]);
    k++;
    }else{
    img[n] = bin_input[i];
    if(Math.abs(img[n]) > max_value_im){
    max_value_im = Math.abs(img[n]);
    n++;
    Then I create an array with the absolute value of complex number:for (int i=0;i < SIZE_X/2*SIZE_Y; i++){
    mag[i] = (float) (Math.sqrt(Math.pow(real[i]/max_value_re,2) + Math.pow(img[i]/max_value_im,2)));
    Now I have an array of float with values from 0 and 1. I tried to create a gray scale image because in the XML file it says that the number of channels is 1:BufferedImage theImage = new BufferedImage(SIZE_X/2, SIZE_Y, BufferedImage.TYPE_4BYTE_ABGR);
    WritableRaster wr = (WritableRaster) theImage.getData();
    wr.setPixels(0, 0, SIZE_X/2, SIZE_Y, mag);
    File outputfile = new File("C:\\Sviluppo\\workspace\\Java\\SAR\\Milano.png");
    try {
    ImageIO.write(theImage, "png", outputfile);
    } catch (IOException e) {
    // TODO Auto-generated catch block
    e.printStackTrace();
    The problem is that the image is all black as if the method is not able to interpret the float values and puts everything at zero.
    First of all, do you think the process can be right or is there some logical/theorical error? If it's ok, How can I fix the problem?
    Thank you.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Script help for dated folder/file

    would anyone mind helping me finalize an issue i have been needing to finalize? i have gotten some help on creating a script that creates a file or folder with the current date but i am not technically competent enough with applescript or chron or any of these things. i can handle terminal pretty much but some of the explanations while obviously complete have got me confused.
    can anyone take a look at the first one here and just tell me how to get off the blocks with this?
    apparently i need to /copy/ and paste the text into a text editor and save as a .pl file by converting the file extension or is this wrong? it seems to me like the next step is in terminal so with a question or two i am sure i can handle this second part...
    https://discussions.apple.com/message/18109918#18109918
    this is another version but the first seems like i have more editing control or may be more direct for my needs(?).
    https://discussions.apple.com/thread/3526097?start=15&tstart=0

    Well, since you have issues with copying, pasting, and saving a file in the GUI, the second option may be your best choice. Setting up crontab requires some proficiency using the vi text editor.

  • Basic script help for a newbie?!?!

    Need help with a basic script, I need to display 5 input fields in a single dynamic field. And i need them to have a certain order of display, ie: input 1 is displayed on line 1, 2 on the next line, etc. any help would be appreciated
    I have been trying various scripts but i either make the second input field replace the first one, or i cant get the vars to populate the field with a button.. Im kinda lost.

    Show what you have tried so far that give you the results where you either replace fields or can't get vars to populate them with a button.

  • Urgent !!! - Java script help for events in adobe form

    Hi ,
    We have requirement  where we have 5 buttons on interactive form which will retrive data from R/3 system .
    1) How can i distingish the event of each button  ?
    For Ex : We have 5 buttons namely , GetPlantcode , GetStatus, SubmittpSAP etc..
    We hav only 2 events on adobe form - Submit to SAP and SAPCheckFields.
    Please let me know some alternative by which i can sent some variable to webDynpro which distinguishes them.
    2) How to set a value for the context variable on button click event ?
    Ex : I have a context node ( data node ) bind to adobe interactive adobe component on a webDynpro application. If i want to set Selectindicator ( value attribute in data Node ) a value on a button click , Please let me know the java script how i can do this.
    Happy New Year for all
    Nanda

    Hi ,
    We found one work around for this. It seems to solve our issue for now.
    Set a text field on adobe and try to set it with some value in each button click. We can get retrived that value in webdypro application through context bind value node to text field.
    Using the value in the value node we have applied different logic in same event submit to SAP.
    Nanda

  • Script help for people and group sharepoint field

    Hello ,
    I want to perform a check by using javascript for people picker controls
    sudhanshu sharma Do good and cast it into river :)

    Hi,
    According to your post, my understanding is that you wanted to perform a check using JavaScript for people picker controls.
    Did you mean you wanted to make a validation of people picker control?
    You can do the steps as below.
    Just Add a content editor webpart in you list form(NewForm.aspx or EditForm.aspx) and put the script below: To add CWEP to you list form you can refer Link
    2. Add your 'Control UserField_upLevelDiv ID'(Using View Source you can get upLevelDiv  id of that contol)
    <script type="text/javascript">
    function getPickerInputElement(identifier)
    var tags = document.getElementsByTagName('DIV');
    for (var i=0; i < tags.length; i++)
    var tempString = tags[i].id;
    if ((tempString.indexOf('UserField_upLevelDiv') > 0))
    if(identifier == tempString)
    var innerSpans = tags[i].getElementsByTagName("SPAN");
    for(var j=0; j < innerSpans.length; j++)
    if(innerSpans[j].id == 'content')
    return innerSpans[j].innerHTML;
    return null;
    var PickerPerson = getPickerInputElement('Control UserField_upLevelDiv ID');
    alert(PickerPerson);
    // For Validation
    if(PickerPerson == null)
    alert('Please enter PP value.');
    return false;
    </script>
    More information:
    http://ankursharepoint.blogspot.in/2012/10/javascript-validation-of-people-picker.html
    There are some similar threads for your reference.
    http://social.msdn.microsoft.com/Forums/en-US/f1c2a651-a0fb-484d-af33-e7084439b6c8/validate-sharepoint-people-picker-using-javascript?forum=sharepointgeneralprevious
    http://social.msdn.microsoft.com/Forums/en-US/df1664c6-a799-4f2b-8f9e-ac8c915c91f6/how-to-validate-people-picket-control-at-client-side-using-javascriptdesigner-in-new-formaspx?forum=sharepointgeneralprevious
    http://social.msdn.microsoft.com/Forums/en-US/9021f00f-8830-4c3a-bdf1-03be84cfb6ca/people-picker-required-field-validation?forum=sharepointdevelopmentprevious
    Thanks & Regards,
    Jason
    Jason Guo
    TechNet Community Support

  • Help for Image Distortion Anyone?

    Is there an easy way to get one line of distortion through text like shown in the picture?
    or maybe a similar effect?
    Thank you for any suggestions.

    Good day!
    Depending on the intended use of the text it might be advisable to use vector data.
    If you want to use pixel data there are several options.
    I would recommend using the Filter Displace as a Smart Filter with a custom Displacement Map.
    Regards,
    Pfaffenbichler

  • Need help for image flipping

    How can i flip an image without using g.drawImage method
    bcos i have already used this method in
    public void paint(Graphics g)
    and i can not use this method again it print out errors..
    i want to use anthoer g.drawimage

    here's a short program that loads an image, flips it, and shows it on screen:import java.awt.geom.AffineTransform;
    import java.awt.image.AffineTransformOp;
    import java.awt.image.BufferedImage;
    import java.io.File;
    import javax.imageio.ImageIO;
    import javax.swing.ImageIcon;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    class Flip {
        public static void main(String[] args) throws Exception {
         // Load jpg file to a BufferedImage.
         File f = new File("/home/jsalonen/Desktop/small.jpg");
         BufferedImage bi = ImageIO.read(f);
         // Flip that image.
         BufferedImage flipped = new BufferedImage(
                       bi.getHeight(),
                       bi.getWidth(),
                       BufferedImage.TYPE_INT_RGB);
         AffineTransform trans = new AffineTransform(0, 1,  1, 0, 0, 0);
         AffineTransformOp op = new AffineTransformOp(trans,
                       AffineTransformOp.TYPE_NEAREST_NEIGHBOR);
         op.filter(bi, flipped);
         // Show it on screen.
         JFrame jf = new JFrame("Flip");
         jf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
         JLabel showLabel = new JLabel(new ImageIcon(flipped));
         jf.getContentPane().add(showLabel);
         jf.pack();
         jf.show();
    }

  • Acrobat Help | Edit images or objects in a PDF

    This question was posted in response to the following article: http://helpx.adobe.com/acrobat/using/edit-images-or-objects-pdf.html

    WHEN I ADD AN IMAGE INTO A .PDF THE GRIP HANDLES DO NOT ALLOW ME TO RESIZE THE IMAGE.
    INSTEAD I GET BLUE LINES ALONG THE SIDE THAT I CLICK ON AND THE WHOLE IMAGE MOVES WITHOUT RESIZING.
    IT WORKED PROPERLY A FEW DAYS AGO NOW I DO NOT KNOW WHAT IS WRONG.
    THANKS, PETER

Maybe you are looking for