Announcement

Collapse
No announcement yet.

PDF

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • 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?

  • #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


    • #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


      • #4
        Re: PDF

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

        Comment


        • #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