Really basic picture question

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • brohan
    Forum Member
    • Jun 2008
    • 9

    Really basic picture question

    I know how to use the Quick Action to get a single picture to open. I am at a loss however as to how to write a script to open several pictures at once. When I use the File.Open, nothing opens up, even when I use only one line of code and I ask it to open only one picture (.jpg). I did not move the picture to the project directory, as the tutotial says that AutoPlay will automatically copy the files from any directory on my computer to the project directory. How can I get AutoPlay to open several .jpg files at once?

    Thank you for your help
  • RizlaUK
    Indigo Rose Customer
    • May 2006
    • 5478

    #2
    File.Open would be the correct way to open a file using the system default for that file, if you used File.Open and it did not work then post your code.

    remember, if useing pic and fax viewer, only one image can be viewed at a time so if you call File.Open 10 times only the last image will be displayed.
    Embrace change in your life, you never know, it could all work out for the best

    Comment

    • brohan
      Forum Member
      • Jun 2008
      • 9

      #3
      Here is my code:

      File.Open("AutoPlay\\Docs\\Main_Room_Panorama", "", SW_SHOWNORMAL);

      Please keep in mind that the path to the actual file on my hard drive is C:\Documents and Settings\Brian J. Rohan\Desktop\Main_Room_Panorama.jpg

      I left the code line as "" as I was under the impression that AutoPlay will automatically move the necessary picture file to the root directory of the CD when publishing the final project (and also when previewing the project)

      Comment

      • longedge
        Indigo Rose Customer
        • Aug 2003
        • 2496

        #4
        Try -

        Code:
        File.Open("C:\\Documents and Settings\\Brian J. Rohan\\Desktop\\Main_Room_Panorama.jpg", "", SW_SHOWNORMAL);
        AMS moves project assets to it's folder structure as they are used so if for instance you had inserted an image object on your page and specified the above file, then it would have been copied into the images folder.

        That is not what you are doing though. You are simply opening a file that exists somewhere by telling AMS to open it using the default viewer as specified on the system on which the application is running. This is done by invoking the file associations on the computer i.e. what happens when you double click a file in a windows explorer window. If you want to actually include the image on the page you have to insert an image object as I said.

        Comment

        Working...
        X