Reply to Thread

Post a reply to the thread: ZIP does not like spaces in path

Your Message

Click here to log in

What's the name of our main installation product (in uppercase letters), directly followed by the current year?

 

You may choose an icon for your message from this list

Additional Options

  • Will turn www.example.com into [URL]http://www.example.com[/URL].

Topic Review (Newest First)

  • 07-22-2011, 12:02 AM
    linder

    Re: ZIP does not like spaces in path

    You did not waste my time at all

    Always ask if there is any question!

    Friedrich
  • 07-21-2011, 11:10 PM
    CMS Software

    Re: ZIP does not like spaces in path

    Oh, Great, it's operator error again!!!

    Sorry I wasted your time, but thanks for the reply. Maybe you should open a thread for stupid operator errors and I'll just post all my questions in there!<G>

    Next question I have I'll research it MUCH more before posting. This is embarrassing.

    -O. D.-

    Quote Originally Posted by linder View Post
    Hello,

    Taken from the manual:

    [in] String that specifies the full paths to all of the files you want to add (this can include the wildcards "*" and "?"). Please put double-quotes around the file specification if you are processing "long" file names.

    Just put double-quotes around the "long" filename specification and you are done

    Does this help?

    Friedrich
  • 07-21-2011, 12:05 AM
    linder

    Re: ZIP does not like spaces in path

    Hello,

    Taken from the manual:

    [in] String that specifies the full paths to all of the files you want to add (this can include the wildcards "*" and "?"). Please put double-quotes around the file specification if you are processing "long" file names.

    Just put double-quotes around the "long" filename specification and you are done

    Does this help?

    Friedrich
  • 07-20-2011, 11:13 PM
    CMS Software

    ZIP does not like spaces in path

    I have the following line in a new install script which is designed to create a backup for the end user and not actually install anything.

    Zip Files from "C:\ProgramData\CMS APPS\SIR\*.*" to "C:\CMS APPS\BKUP\SIR\SIRBKUP.ZIP" [Recurse]

    All of the folders listed in the line already exist, having been placed there by the earlier install program. The install kept blowing up with an error about not being able to locate "APPS\SIR" but it did produce a zip file. The zip file contained ALL the folders under ProgramData, not just the specified one.

    Note that the destination folder path contains a space ("C:\CMS APPS\BKUP\SIR\SIRBKUP.ZIP") and that does not cause an error message.

    Next I renamed the "ProgramData\CMS APPS" folder to "ProgramData\CMSAPPS" (no spaces) and changed the line of code in the script to also not use a space on the source folder.

    It worked!

    Is this a bug or WAD (Working As Designed)? Seems peculiar that the destination is OK with spaces in the folder paths, but the source is not... In XP, Vista and Win7 spaces are very common in folder paths.

    I have not had time to test the unzip function to see if it allows spaces in the source and destination paths. Maybe tomorrow.

    One other interesting thing, not a bug but something I need to remember. When doing a zip using the name and path of an existing zip, new files are added to the existing zip. Interestingly, if a particular data file that was zipped earlier is removed from the user's machine and the zip is built using the exact same path and file name, the "old" file is not removed from the zip file. That actually could be a very handy feature if a customer accidentally deletes a data file and then does a backup. The missing file would still be in the zip file and could be recovered. That's a Good Thing!

    CMS

Posting Permissions

  • You may post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •