Keeping paths when zipping files

Hi,
I have a problem :
I have to zip a directory that contains sub-directories, and mail this zip file.
I've managed to get all the files into one zip, but when I unzip it (winzip), all the paths are gone ...
any ideas that can help me to keep them?

if you use winzip, you can just highlight all the directories/files you want in it and right click (add to zip), and all the paths will be kept.

Similar Messages

  • My browsers on Mac keep crashing when attaching files

    My browsers on MBP keep crashing when attaching files to my emails. I had the same problem with Safari, Firefox browsers and also with Gmail, Yahoo accounts. I emptied the cache, reset safari. It says its due to flash player..Uninstalled flash player, re-downloaded it, made safari work at 32 bit, made gmail attachments work at basic settings.. I repaired permissions using utilities ..also I have no internet plugins, no yahoo browser plus but nothing seems to work.. Any help? Many thanks

    This forum is for the MacBook Pro hardware.  You might get a better answer in the Safari forum, but you will have to provide more information there. 
    https://discussions.apple.com/community/mac_os/safari

  • Wrong path when zip a file

    When I try to Zip a file(backup.zip) everything is good except one thing.
    When I use WinZip to unzip the file, the path for the file contains all subdirectories eg. c:\mycatalog\backup\db\data.data
    I would like the path to be like: backup\db\data.data
    The code:
    pathName is "c:\mycatalog"
    fileName is "backup"
    public class Zip {
    private static ZipOutputStream zos;
    * Creates a Zip archive. If the name of the file passed in is a
    * directory, the directory's contents will be made into a Zip file.
    public static void makeZip(File pathName, String fileName)
    throws IOException, FileNotFoundException
    File file = new File(pathName,fileName);
    zos = new ZipOutputStream(new FileOutputStream(pathName.toString()+"\\"+fileName+".lum"));
    //Call recursion.
    recurseFiles(file);
    //We are done adding entries to the zip archive,
    //so close the Zip output stream.
    zos.close();
    * Recurses down a directory and its subdirectories to look for
    * files to add to the Zip. If the current file being looked at
    * is not a directory, the method adds it to the Zip file.
    private static void recurseFiles(File file)
    throws IOException, FileNotFoundException
    if (file.isDirectory()) {
    //Create an array with all of the files and subdirectories
    //of the current directory.
    String[] fileNames = file.list();
    if (fileNames != null) {
    //Recursively add each array entry to make sure that we get
    //subdirectories as well as normal files in the directory.
    for (int i=0; i<fileNames.length; i++) {
    recurseFiles(new File(file, fileNames));
    //Otherwise, a file so add it as an entry to the Zip file.
    else {
    byte[] buf = new byte[1024];
    int len;
    //Create a new Zip entry with the file's name.
    ZipEntry zipEntry = new ZipEntry(file.toString());
    //Create a buffered input stream out of the file
    //we're trying to add into the Zip archive.
    FileInputStream fin = new FileInputStream(file);
    BufferedInputStream in = new BufferedInputStream(fin);
    zos.putNextEntry(zipEntry);
    //Read bytes from the file and write into the Zip archive.
    while ((len = in.read(buf)) >= 0) {
    zos.write(buf, 0, len);
    //Close the input stream.
    in.close();
    //Close this entry in the Zip stream.
    zos.closeEntry();

    Sorry, I want the path to be like: "\db\data.data"

  • Path in ZIP Files

    I have a program that compresses files into a ZIP File.
    How do you get the data extractable in something like WinZip and how do you get Ride of the Path in WinZip?

    Well what I'm trying to do is use the class files in java.util.zip.* to make a program that compresses files into a ZIP Archive. I figured out the question you didn't understand. What I'm trying to do right now is get the data in the archive extractable. When I open my archive that I created with my program, WinZip says that the enties are there. When I try to extract them WinZip crashes. I used a code that is something like this:
    ZipOutputStream zos = new ZipOutputStream(new FileOutputStream(outzip));
    int q = 0;
    for (q = 0; q < infile.length; q++) {
    FileInputStream in = new FileInputStream(infile[q]);
    size = in.available();
    byte b[] = new byte[size];
    in.read(b);
    File f = new File(infile[q]);
    ZipEntry ze = new ZipEntry(f.getPath());
    zos.setLevel(9);
    ze.setTime(f.lastModified());
    zos.putNextEntry(ze);
    zos.write(b);
    zos.closeEntry();
    in.close();
    zos.flush();
    zos.close();
    Infile is an array of file names in the form of strings. Then the program loops through them strings turning each into a file so that it is written without a path name (which wa part of my last problem) into the zip file.

  • Motion 3 Keeps Crashing When Opening File

    Motion 3 keeps crashing when I try to open a file that has alot of moving text. I have words that keep falling like rain onto other words. Once in a blue moon I can get it to open and can edit it, but after I save it's a crap shoot to when it will open again. Any suggestions?
    I have tried putting the text into another program (Adobe Illustrator) but it doesn't work as nice or as quickly. Thanks.

    IMpossible to tell from here but try this:
    If it gets opened, immediately save a copy. Quit Motion
    In the Finder, make at least three or four more copies of the copy. Leave the original alone.
    Open one of the copies, delete half of the layers.
    Close it.
    Open another copy. Delete the other half of the layers.
    See where this is going? You're going to do some binary test to try to figure out which layers are making problems.
    bogiesan

  • MFT 12.1.3 does not decompress all files when zip file size 2G

    Hi,
    I am having an issue with MFT and SOA. In my setup MFT receives zip files, decompress the zip file into several other files and send them as file reference to a SOA process for further processing. Now I am getting a very large file with a size of around 2 G containing 4 files where the larges file is 5G uncompressed. However when I submit this file to the MFT embedded ftp server MFT moves the file to the payload area, and start decompressing.It stops after compressing the first file. Can't find any error message in the server logs.
    Has somebody seen this kind of behavior?
    Any tip or tricks where to look to find more info about what could be the issue?
    Thanks in advance Frans

    With iPhoto crashing while trying to create a new library makes me think the application may the culprit an you may have to reinstall it. Have you tried the library wihile booted into  Safe Mode?
    Are you able to boot into another user account on your Mac and run iPhoto there?  If so then your home account looks suspicious.
    OT

  • Keeping metadata when moving files?

    I have LR 2.6. I have a laptop which doesn't have enough disk space for all of my photos, which go back to 2000 (around 22,000). I have three external drives, one is the main one and the other two are backups at this point (smaller space). I need to get another.
    I had been importing the photos from the card to my laptop. In the past I've been able to keep a year on the laptop, but with my current camera I don't have enough room, just enough for a couple of months. What I had been doing is copying the older ones to the external drive outside of LR, and deleting them from the laptop, not realizing that I was losing my keywords, titles and I'm not sure what else. I didn't have the settings to create xmp files until recently. The last time I moved files I did it within LR, but it only moved the RAW files, not the xmp.
    I had also been keeping all the data in one catalog. I went back to an older one that had a lot of what I'd lost and tried to update that, but there are still around 1,300 files without keywords. And now I have metadata conflicts (not sure if that's from the xmp settings or not).
    1-What's the best way to deal with this so that I don't lose my info?
    2-Is there any way to easily tell what the conflict is, or at least be able to tell in general where the "best" metadata is?
    3-Is there any way to merge metadata from a selection of files to another catalog?
    4-And if not answered in one of the above, what's the best way to fix this mess?
    Thanks in advance.

    The last time I moved files I did it within LR, but it only moved the RAW files, not the xmp.
    This can't possibly be correct . If the .xmp file exists, and you move the photo within LR, the xmp moves with it.
    I had also been keeping all the data in one catalog. I went back to an older one that had a lot of what I'd lost and tried to update that, but there are still around 1,300 files without keywords. And now I have metadata conflicts (not sure if that's from the xmp settings or not).
    I think the only way you can have a metadata conflict is a conflict between the catalog's metadata and the xmp metadata.
    1-What's the best way to deal with this so that I don't lose my info?
    2-Is there any way to easily tell what the conflict is, or at least be able to tell in general where the "best" metadata is?
    3-Is there any way to merge metadata from a selection of files to another catalog?
    4-And if not answered in one of the above, what's the best way to fix this mess?
    There is no best way to fix this mess. Any way to fix it is probably going to involve a lot of tedious work on your part to straighten things out.
    You can merge the metadata from the older catalog into the newer catalog. In the older catalog, select the desired photos and then File->Export as Catalog. Then, in the newer catalog, select File->Import from Catalog. This will cause LR to replace the metadata in the new catalog with the metadata in the older catalog. An alternative when you Import from Catalog is to tell LR to create virtual copies, so you have both sets of metadata in a single LR catalog, which you can then view and decide which one you want to keep.
    Good luck

  • IMac is very slow and sluggish, keeps churning when editing files or on internet

    My iMac is running slow and sluggish, it takes several minutes to edit a word document or search the internet ... intermittently it runs great but productivity is near zero when to edit a sentence in a Word document takes several minutes.  When typing an email the cursor stops and if you keep typing it eventually fills in what was typed even though you can't see it when typing. Ran Etrecheck ... report is attached.
    Problem description:
    iMac mid 2010 is running very slow … takes too long to edit documents and open internet sites … increased RAM a month ago from 4 to 12 GB
    EtreCheck version: 2.1.8 (121)
    Report generated March 6, 2015 at 8:25:35 AM CST
    Download EtreCheck from http://etresoft.com/etrecheck
    Click the [Click for support] links for help with non-Apple products.
    Click the [Click for details] links for more information about that line.
    Hardware Information: ℹ️
        iMac (27-inch, Mid 2010) (Technical Specifications)
        iMac - model: iMac11,3
        1 3.2 GHz Intel Core i3 CPU: 2-core
        12 GB RAM Upgradeable
            BANK 0/DIMM0
                2 GB DDR3 1333 MHz ok
            BANK 1/DIMM0
                2 GB DDR3 1333 MHz ok
            BANK 0/DIMM1
                4 GB DDR3 1333 MHz ok
            BANK 1/DIMM1
                4 GB DDR3 1333 MHz ok
        Bluetooth: Old - Handoff/Airdrop2 not supported
        Wireless:  en1: 802.11 a/b/g/n
    Video Information: ℹ️
        ATI Radeon HD 5670 - VRAM: 512 MB
            iMac 2560 x 1440
    System Software: ℹ️
        OS X 10.10.2 (14C109) - Time since boot: 3 days 23:34:34
    Disk Information: ℹ️
        ST31000528AS disk0 : (1 TB)
            EFI (disk0s1) <not mounted> : 210 MB
            Macintosh HD (disk0s2) / : 999.35 GB (636.35 GB free) - 523 errors
            Recovery HD (disk0s3) <not mounted>  [Recovery]: 650 MB
        OPTIARC DVD RW AD-5680H 
    USB Information: ℹ️
        HP Officejet Pro 8500 A910
        Apple, Inc. Keyboard Hub
            Apple, Inc Apple Keyboard
        Apple Computer, Inc. IR Receiver
        Apple Inc. Built-in iSight
        Hewlett-Packard HP LaserJet Professional P1606dn
        Neat NeatConnect Scanner
        Apple Inc. BRCM2046 Hub
            Apple Inc. Bluetooth USB Host Controller
        Apple Internal Memory Card Reader
    Gatekeeper: ℹ️
        Mac App Store and identified developers
    Kernel Extensions: ℹ️
            /System/Library/Extensions
        [not loaded]    com.marvell.kext.USBGenericPrinterClass (1.0.0) [Click for support]
    Launch Agents: ℹ️
        [loaded]    com.carbonite.launchd.carbonitealerts.plist [Click for support]
        [running]    com.carbonite.launchd.carbonitestatus.plist [Click for support]
        [running]    com.citrixonline.GoToMyPC.LaunchAgent.plist [Click for support]
    Launch Daemons: ℹ️
        [running]    com.carbonite.launchd.carbonitedaemon.plist [Click for support]
        [running]    com.citrixonline.GoToMyPC.CommAgent.plist [Click for support]
        [loaded]    com.microsoft.office.licensing.helper.plist [Click for support]
        [loaded]    com.oracle.java.JavaUpdateHelper.plist [Click for support]
        [loaded]    com.roamingclient.cell.mac.tm.roamingclient.plist [Click for support]
        [running]    com.tmobile-rocket20.zerocd.plist [Click for support]
    User Launch Agents: ℹ️
        [loaded]    com.adobe.ARM.[...].plist [Click for support]
        [failed]    com.citrixonline.GoToMeeting.G2MUpdate.plist [Click for support] [Click for details]
        [loaded]    com.google.keystone.agent.plist [Click for support]
        [running]    com.hp.printerAgent.plist [Click for support]
    User Login Items: ℹ️
        None
    Internet Plug-ins: ℹ️
        JavaAppletPlugin: Version: Java 7 Update 51 Check version
        FlashPlayerDebugger-10.6: Version: 11.2.202.235 [Click for support]
        AdobePDFViewerNPAPI: Version: 10.1.13 [Click for support]
        AdobePDFViewer: Version: 10.1.13 [Click for support]
        Flash Player: Version: 11.2.202.235 Outdated! Update
        Default Browser: Version: 600 - SDK 10.10
        QuickTime Plugin: Version: 7.7.3
        SharePointBrowserPlugin: Version: 14.4.8 - SDK 10.6 [Click for support]
        Silverlight: Version: 5.1.20513.0 - SDK 10.6 [Click for support]
        DirectorShockwave: Version: 11.5.9r620 [Click for support]
        iPhotoPhotocast: Version: 7.0 - SDK 10.8
    User internet Plug-ins: ℹ️
        CitrixOnlineWebDeploymentPlugin: Version: 1.0.105 [Click for support]
    3rd Party Preference Panes: ℹ️
        Carbonite  [Click for support]
        Flash Player  [Click for support]
        GoToMyPC Preferences  [Click for support]
        Growl  [Click for support]
    Time Machine: ℹ️
        Auto backup: YES
        Volumes being backed up:
            Macintosh HD: Disk size: 999.35 GB Disk used: 363.00 GB
        Destinations:
            Taylor Technology Time Caps [Network]
            Total size: 2.00 TB
            Total number of backups: 91
            Oldest backup: 2014-01-13 06:38:23 +0000
            Last backup: 2015-03-06 14:07:22 +0000
            Size of backup disk: Adequate
                Backup size 2.00 TB > (Disk used 363.00 GB X 3)
    Top Processes by CPU: ℹ️
            81%    CarboniteDaemon
             4%    WindowServer
             3%    Neat
             1%    HP Scanner 3
             0%    Microsoft Word
    Top Processes by Memory: ℹ️
        3.05 GB    Neat
        1.46 GB    CarboniteDaemon
        232 MB    Microsoft Word
        232 MB    Finder
        219 MB    WindowServer
    Virtual Memory Information: ℹ️
        327 MB    Free RAM
        4.78 GB    Active RAM
        4.18 GB    Inactive RAM
        1.15 GB    Wired RAM
        125.62 GB    Page-ins
        298 MB    Page-outs
    Diagnostics Information: ℹ️
        Feb 12, 2015, 10:18:58 AM    /Library/Logs/DiagnosticReports/Kernel_2015-02-12-101858_[redacted].panic [Click for details]

    Matt ... got it done, recovery repair said Hard Drive OK.  Re-ran EtreCheck report attached ... still having the same issues.  Everything is fully backed up to Carbonite and Time Machine ... let me know if you see other conflicts or if it is the hard drive I will work to get it repaired.
    Thanks.
    EtreCheck version: 2.1.8 (121)
    Report generated March 6, 2015 at 9:28:28 AM CST
    Download EtreCheck from http://etresoft.com/etrecheck
    Click the [Click for support] links for help with non-Apple products.
    Click the [Click for details] links for more information about that line.
    Hardware Information: ℹ️
        iMac (27-inch, Mid 2010) (Technical Specifications)
        iMac - model: iMac11,3
        1 3.2 GHz Intel Core i3 CPU: 2-core
        12 GB RAM Upgradeable
            BANK 0/DIMM0
                2 GB DDR3 1333 MHz ok
            BANK 1/DIMM0
                2 GB DDR3 1333 MHz ok
            BANK 0/DIMM1
                4 GB DDR3 1333 MHz ok
            BANK 1/DIMM1
                4 GB DDR3 1333 MHz ok
        Bluetooth: Old - Handoff/Airdrop2 not supported
        Wireless:  en1: 802.11 a/b/g/n
    Video Information: ℹ️
        ATI Radeon HD 5670 - VRAM: 512 MB
            iMac 2560 x 1440
    System Software: ℹ️
        OS X 10.10.2 (14C109) - Time since boot: 0:2:41
    Disk Information: ℹ️
        ST31000528AS disk0 : (1 TB)
            EFI (disk0s1) <not mounted> : 210 MB
            Macintosh HD (disk0s2) / : 999.35 GB (643.46 GB free) - 21 errors
            Recovery HD (disk0s3) <not mounted>  [Recovery]: 650 MB
        OPTIARC DVD RW AD-5680H 
    USB Information: ℹ️
        HP Officejet Pro 8500 A910
        Apple, Inc. Keyboard Hub
            Apple Inc. iPhone
            Apple, Inc Apple Keyboard
        Apple Inc. Built-in iSight
        Apple Computer, Inc. IR Receiver
        Hewlett-Packard HP LaserJet Professional P1606dn
        Neat NeatConnect Scanner
        Apple Inc. BRCM2046 Hub
            Apple Inc. Bluetooth USB Host Controller
        Apple Internal Memory Card Reader
    Gatekeeper: ℹ️
        Mac App Store and identified developers
    Kernel Extensions: ℹ️
            /System/Library/Extensions
        [not loaded]    com.marvell.kext.USBGenericPrinterClass (1.0.0) [Click for support]
    Launch Agents: ℹ️
        [loaded]    com.carbonite.launchd.carbonitealerts.plist [Click for support]
        [running]    com.carbonite.launchd.carbonitestatus.plist [Click for support]
        [running]    com.citrixonline.GoToMyPC.LaunchAgent.plist [Click for support]
    Launch Daemons: ℹ️
        [running]    com.carbonite.launchd.carbonitedaemon.plist [Click for support]
        [running]    com.citrixonline.GoToMyPC.CommAgent.plist [Click for support]
        [loaded]    com.microsoft.office.licensing.helper.plist [Click for support]
        [loaded]    com.oracle.java.JavaUpdateHelper.plist [Click for support]
        [loaded]    com.roamingclient.cell.mac.tm.roamingclient.plist [Click for support]
        [running]    com.tmobile-rocket20.zerocd.plist [Click for support]
    User Launch Agents: ℹ️
        [loaded]    com.adobe.ARM.[...].plist [Click for support]
        [loaded]    com.citrixonline.GoToMeeting.G2MUpdate.plist [Click for support]
        [loaded]    com.google.keystone.agent.plist [Click for support]
        [running]    com.hp.printerAgent.plist [Click for support]
    User Login Items: ℹ️
        None
    Internet Plug-ins: ℹ️
        JavaAppletPlugin: Version: Java 7 Update 51 Check version
        FlashPlayerDebugger-10.6: Version: 11.2.202.235 [Click for support]
        AdobePDFViewerNPAPI: Version: 10.1.13 [Click for support]
        AdobePDFViewer: Version: 10.1.13 [Click for support]
        Flash Player: Version: 11.2.202.235 Outdated! Update
        Default Browser: Version: 600 - SDK 10.10
        QuickTime Plugin: Version: 7.7.3
        SharePointBrowserPlugin: Version: 14.4.8 - SDK 10.6 [Click for support]
        Silverlight: Version: 5.1.20513.0 - SDK 10.6 [Click for support]
        DirectorShockwave: Version: 11.5.9r620 [Click for support]
        iPhotoPhotocast: Version: 7.0 - SDK 10.8
    User internet Plug-ins: ℹ️
        CitrixOnlineWebDeploymentPlugin: Version: 1.0.105 [Click for support]
    3rd Party Preference Panes: ℹ️
        Carbonite  [Click for support]
        Flash Player  [Click for support]
        GoToMyPC Preferences  [Click for support]
        Growl  [Click for support]
    Time Machine: ℹ️
        Auto backup: YES
        Volumes being backed up:
            Macintosh HD: Disk size: 999.35 GB Disk used: 355.88 GB
        Destinations:
            Taylor Technology Time Caps [Network]
            Total size: 2.00 TB
            Total number of backups: 91
            Oldest backup: 2014-01-13 06:38:23 +0000
            Last backup: 2015-03-06 14:07:22 +0000
            Size of backup disk: Adequate
                Backup size 2.00 TB > (Disk used 355.88 GB X 3)
    Top Processes by CPU: ℹ️
            25%    CarboniteDaemon
             3%    WindowServer
             2%    systemstatsd
             1%    launchd
             0%    HP Scanner 3
    Top Processes by Memory: ℹ️
        129 MB    CarboniteDaemon
        103 MB    ocspd
        77 MB    Safari
        52 MB    Dock
        39 MB    mds_stores
    Virtual Memory Information: ℹ️
        9.94 GB    Free RAM
        1.48 GB    Active RAM
        539 MB    Inactive RAM
        922 MB    Wired RAM
        1.01 GB    Page-ins
        0 B    Page-outs
    Diagnostics Information: ℹ️
        Mar 6, 2015, 09:24:22 AM    Self test - passed
        Feb 12, 2015, 10:18:58 AM    /Library/Logs/DiagnosticReports/Kernel_2015-02-12-101858_[redacted].panic [Click for details]

  • Clean Re-install? Keeps Freezing when importing files.

    Hope someone can help...I can't stop my photoshop from searching for files to import. No matter what I do it freezes on the importing files and never moves...I am beyond frustrated to the point i have uninstalled and reinstalled to see if I can get it to stop by it keeps starting with that Can I completely delete and re-install clean and re-program where to get files? I think I moved files without doing it through Adobe and it hasn't been the same since but i thought my external drive was dying.

    You will need to turn off Watch folder service. Please follow these steps-
    On desktop press 'CTRL+R' key to open 'Run' dialog'. Type 'services.msc' and hit enter
    Check for 'Adobe Active File Monitor v9' and right click it > choose Stop.
    Thanks
    Andaleeb

  • Ps cs4 keeps crashing when opening files..

    ive never had this problem before, my system is freshly formatted and ps is acting up.. here is the error report:
      Problem Event Name: APPCRASH
      Application Name: Photoshop.exe
      Application Version: 11.0.2.0
      Application Timestamp: 4bf2d91c
      Fault Module Name: BIB.dll
      Fault Module Version: 1.2.1.1744
      Fault Module Timestamp: 48b5fcc0
      Exception Code: c0000005
      Exception Offset: 000000000001a318
      OS Version: 6.1.7601.2.1.0.256.1
      Locale ID: 1033
      Additional Information 1: 83f8
      Additional Information 2: 83f885d706e07a421d55db4a82e4b32d
      Additional Information 3: 0394
      Additional Information 4: 03949964d3996ee575d5c455985c7e4f
    can anyone tell me what to do? btw ive tried resetting ps and didnt work..

    Here is a quote from a previouos response
    "There is a bib.dll used with Photoshop to access some of our core technology DLLs.
    If it was on a type layer, then it could be due to a corrupt PSD file or a corrupt font file.
    Did you install the latest CS4 update (11.0.2)?
    from http://forums.adobe.com/message/3359026

  • Problem with Java and Zip Files

    Hello there everyone. I have a problem with trying to zip up directories with empty folders in them. They zip fine with my code, but according to winzip, the number of files in the archive is incorrect. It's supposed to have a total of 288 files in it, but when it's zipped up, it only says 284. I mention specifically the "empty directories" note because the zipping works fine without empty folders.
    Below is the code for the zip method:
    public static void zip(File[] list, File zipfile, File zipRoot)
         throws IOException {
          if (!zipfile.exists()) {
                   zipfile.createNewFile();
              else if (!zipfile.isFile()) {
                   throw new IOException("The zip file, " + zipfile.getAbsolutePath()
                             + " is not a file.");
              if (list.length == 0) {
                  LOG.error("The list of files to zip up is empty.");
              for (int i = 0; i < list.length; i++) {
                   if (!list.exists()) {
                        throw new IOException("The file or directory, " + list[i].getAbsolutePath()
                                  + " does not exist.");
              FileOutputStream fos = new FileOutputStream(zipfile);
              ZipOutputStream zos = new ZipOutputStream(fos);
              for (int i = 0; i < list.length; i++) {
                   if (LOG.isDebugEnabled())
                        LOG.debug(i + ": " + list[i].getName());
                   String entryName = getRelativeName(list[i], zipRoot);
                   if (list[i].isDirectory()){
                        if (list[i].listFiles().length == 0){
                             ZipEntry entry = new ZipEntry(entryName + "/");
                             zos.putNextEntry(entry);
                   else {
                        ZipEntry ze = new ZipEntry(entryName);
                        zos.putNextEntry(ze);
                        byte[] buffer = new byte[8096];
                        FileInputStream fis = new FileInputStream(list[i]);
                        int read = 0;
                        read = fis.read(buffer);
                        if (LOG.isDebugEnabled())
                        LOG.debug("\tFound " + read + " bytes.");
                        if (read == -1){
                             //empty file, but add it for preservation.
                             //zos.write(buffer,0,0);
                        while (read != -1) {
                             zos.write(buffer, 0, read);
                             read = fis.read(buffer);
                        fis.close();
                        zos.closeEntry();
              zos.close();
    The files look like they're there, but I need the system to be able to determine the number correctly. 
    Here's the interesting thing:  It zips the files, and then when I use the size() method for zip files in java, it says 284 files.  But when I unzip, it says 288 again.  It's like there's files missing when compressed, but when decompressed, they return.  Note that the files are actually there.  If I open the archive in a third party app such as Winzip AND Winrar AND IZarc, they all show 288 files.  Any idea what would make the number of files appear incorrectly in a zip file when zipped by java with the code above?  Thanks in advance.
    - Chris                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    I figured out the problem. When zipping files in windows using winzip, it doesn't explicitly count folders as a "file/folder" as a file in itself. It will create the folders for files to go in, but the folder itself will not be 'counted' when you query the info of the file itself. You have more control of the zip file in java, and can count the folder as a file or not.

  • How to the link/path of the file being uploaded

    Hi all,
    I am uploading a CSV file in apex3.2 and would like to store the actual path of the file into a custom table. I get the file name as F26222/my_filename.csv from the FILE BROWSE apex item. How can I capture the path also?
    Thanks in advance.
    Movva

    cmovva wrote:
    Hi all,
    I am uploading a CSV file in apex3.2 and would like to store the actual path of the file into a custom table. I get the file name as F26222/my_filename.csv from the FILE BROWSE apex item. How can I capture the path also?For security/privacy reasons recent versions of browsers by default do not send local file path information from File Browse items to the server, nor expose the file path in the control's JavaScript methods. Firefox, Safari and Chrome only provide the filename. IE6 & IE7 still yield the path in Windows format. IE8 and Opera have adopted an irritating approach of replacing the path with a wholly imaginary "C:\fakepath\"&mdash;and this monstrosity has sadly had to be enshrined in the HTML5 spec...
    Changing IE's security config setting “Include local directory path when uploading files” enables the path to be exposed in IE8, but unless you're working in an intranet environment where: IE is the only browser used; it's possible to make remote changes to this setting on every desktop; and this won't break/expose anything else, then trying to achieve this is pointless.
    For more information see:
    http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2009-March/018980.html
    http://blogs.msdn.com/ie/archive/2009/03/20/rtm-platform-changes.aspx
    http://developers.whatwg.org/number-state.html#file-upload-state
    Please search the forum thoroughly before posting: this is the umpteenth time I've provided this information. There's even another live thread on the same topic: +{thread:id=2316750}+

  • How do I open a pw protected zip file?

    This question appears to be different from similar questions asked because I HAVE the password. I really don't want to download extra safe-cracker's-anonymous software to hack into it. The file just never gives me the option of entering it. I have the zip file, I double-click on it, it gives me an error message. I right-click on it but no options there either. How do I open it such that it gives me a chance to unlock it?
    Appreciate the help. (and yeah, I have no idea if I'm in the right community - sorry about that if I'm in the wrong place)

    The zip file format is not a nice, standardized format. You could have a weird zip file that is technically not bad, but isn't supported by the built-in software on Mac OS X. In some cases, when zip files won't open, I've had success opening them with The Unarchiver, which is available both in the App Store and outside it:
    https://itunes.apple.com/us/app/the-unarchiver/id425424353?mt=12
    http://unarchiver.c3.cx
    (I don't know if there's a difference in functionality between the two... there could be, but if there is, I am not aware of it.)
    It's also possible the zip file is corrupted, and won't be openable by anything.

  • Finder is crashing when previewing files

    My finder keeps crashing when previewing files from an external hard drive. It's mov-files and stills(cr2).
    I have files recorded on two separate days. When previewing files day 2 there's no problem but when previewing files from day 1 finder is crashing every time. I have back up of all the files on another drive. On the back up drive there's no problem to preview files.

    That is why I want you to erase it.. so you can get access.. but I cannot trial it for you... I do not have one.. you have to trial it yourself.
    Setup the TC to use Accounts.. not use disk password or device password.. after an erase.
    See if that fixes it.
    See this post for different but maybe related issue.
    https://discussions.apple.com/thread/5146963?tstart=0

  • Premiere Pro crashes when sending files to media encoder

    Premiere Pro CC keeps crashing when sending files to Media Encoder. This is a new problem. I cleaned the cache, typed purge into terminal, checked the sharing in the preferences library and verified/repaired disk permissions. What else can I try? Help, I have urgent deadlines this week!

    I am using the most updated version of PPro CC with OS 10.8.5. It seems to have issues with certain sequences and not others.  It also may be the files themselves.  They play fine in the program viewer and I have sent them to Media Encoder before, but if I create a new sequence with the same settings and copy the files into it, the same thing happens. I have a lot of 29.97 720x480 (1.21 pixels) and 1440x1080 (PAR 1.333) footage to edit together and create dvds out of (not my idea - it's a job) and I am in the middle of trying various ways of encoding to make it as clear as possible.
    Currently I am using 1440x1080i HD anamorphic sequence settings encoding into 1440x1080 p HD anamorphic with frame blending, maximum render quality, Target bit rate of 30 VBR 2 pass. Then combining those files with other sequences into a longer 1440x1080 p HD anamorphic sequence and encoding MPEG 2-DVD NTSC widescreen progressive 100% quality, VBR 2 pass and the output is much better. This has been working, and today suddenly it stopped and started crashing. Any ideas?

Maybe you are looking for

  • Pixelated images after burning

    A friend of mine is using iDVD to create a slideshow of some photos. The photos look great, and after burning, when playing on either tv's or even other computers, no matter the screen size, all the images, as well as the text that pops up, is all pi

  • Changing RSS Feed in iWeb

    I use iWeb'09, GarageBand and MobileMe, and want to find out how to simply change the existing RSS feed for my podcast series in iWeb without resorting to using any further applications. Many thanks in advance.

  • Cursor placement in a GUIBB / Focus Request

    Hello Is it possible to place the cursor in a particular field within a GUIBB? We have the requirement what our application has to support this. In WDA one can set the focus via the interface IF_WD_VIEW and its method request_focus_on_view_elem. Does

  • User exit in equipment

    Dear all, I need to fill equipment type automatically from the field INVNR when i fill invnr and press enter. Is there any user exit i can handle that situation? Thanks

  • Problems with JDAPI Samples

    We are having problems getting the JDAPI samples provided with FormsBuilder9i working correctly. There are a couple of problems that occur. 1) When running GetFormName/GetModuleName the name of the form retrieved with the FormModule.getName() method