PDF

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • Bruce
    Indigo Rose Customer
    • Jun 2001
    • 2133

    PDF

    I want to read a PDF that was put in a temp file (C:\temp) by a password protected Zip and read it with Acrobat that's on my CD. On mouse up I have:

    %ZipPW% = "whateverpassword"
    ZipFile.Extract ( "%SrcDir%\Handbook.zip", "*.*", "C:\temp")
    File.Open (open, "%SrcDir%\Acrobat\AcroRd32.exe^C:\temp\Handbook.pd f")

    It doesn't want to.... :-( Any ideas?
  • kpsmith
    Forum Member
    • Jul 2000
    • 332

    #2
    Re: PDF

    Try using the %Temp% Variable instead and see if it makes a difference. No everyone will have C:\Temp

    Also use a file execute to open Acrobat with the full path to the .pdf you want to open in the command line arguments field.

    %ZipPW% = "whateverpassword"
    ZipFile.Extract ( "%SrcDir%\Handbook.zip", "*.*", "%Temp%")
    File.Execute ("%SrcDir%\Acrobat\AcroRd32.exe", "%Temp%\Handbook.pdf", Continue)

    Comment

    • Derek
      Indigo Rose Customer
      • May 2001
      • 1254

      #3
      Re: PDF

      Hi Bruce

      Dont use the variable for the zip password .. you can define this in Zip.Extract ... check the 'Use Password' box and the following Actions:
      <font color=green>
      Folder.Create ("C:\temp")
      ZipFile.Extract ( "%SrcDir%\MyZips\MyZip.zip", "*.*", "C:/temp")
      File.Open (open, "c:/temp/filename.pdf")</font color=green>

      I believe Zip.Extract will create the folder if it doesnt exist, but just to be safe you can include it anyway.
      File.Open will open the pdf file, or include AR on the CD and use File.Execute if yu wanna stay away from the chance that the end-user doesnt have it anstalled - ie:
      <font color=green>
      Folder.Create ("C:\temp")
      ZipFile.Extract ( "%SrcDir%\MyZips\MyZip.zip", "*.*", "C:/temp")
      File.Execute ("%SrcDir%/Acrobat/Acro32.exe", "c:/temp/filename.pdf", Continue)</font color=green>
      -
      = Derek
      ["All glory comes from daring to begin" - fortune cookie]

      Comment

      • Bruce
        Indigo Rose Customer
        • Jun 2001
        • 2133

        #4
        Re: PDF

        Thanks you guys. Derek, why would I build yours over the other one?

        Comment

        • Derek
          Indigo Rose Customer
          • May 2001
          • 1254

          #5
          Re: PDF

          um ... was thinking about that after I posted ... I guess it depends on what way yur doing it.
          Use which ever works best for yur needs. When i first read the reply, i wondered why you would use a variable when you can just put the password straight into the Zip.Extract dialog, but that depends how yur doing it.
          -
          = Derek
          ["All glory comes from daring to begin" - fortune cookie]

          Comment

          Working...
          X