How to FTP file and extract the zip file automatically?

Hi,
My app needs to FTP another site and also automatically unzip the transferred file over the internet by user clicking on one button. Any experts? thanks.

How do you open a can of beans before you take it out of the pantry?
However I suppose your question only sounded stupid like that, you didn't really mean it that way. One problem is that you didn't mention which way the transfer was going. I assume you are asking about getting a file and unzipping it? Many of the FTP clients described in the article that jmennen referred to allow you to get an InputStream that allows you to read bytes from the server. You would take this InputStream and wrap it in a ZipInputStream. That way you could unzip the file as you transfer it from the server, rather than having to use a temporary file between the two steps.
But if you really meant that you wanted the unzipping to take place on the server before you did the download, no, you can't do that.

Similar Messages

  • How to zip a folder containing subfolders with files and download the zip file in silverlght 4

    private void hbtnDownloadReceipt_Click(object sender, RoutedEventArgs e)
               try
                    string Docpath = "ClaimsDetails/" + "20tech" + "/" + PaymentAdviceUNo;
                    string dd = "ClaimsDetails/";
                    Uri uri = new Uri(Application.Current.Host.Source, "/" + Docpath);
                    Uri uri1 = new Uri(Application.Current.Host.Source, "/" + dd);
                    string path = uri.AbsoluteUri.ToString();
                    path1 = uri1.AbsoluteUri.ToString();
                    //HtmlPage.Window.Eval("window.open('" + path + "')");
                catch (Exception ex)
                    ex.Data.Clear();
    1) Here "path" is D:\\TL 24-12-2014 \\OfficeConnect_17_10\\OfficeConnect.Web\\ClaimsDetails\\20tech\\PaymentAdviceUNo.     
    2) In path "PaymentAdviceUNo" is the folder containing subfolders which i want to zip.
    Thanks in Advance.

    Hi,
    You can download a zip file like any files with the Webclient class, look at the details and examples in the msdn documentation for downloading content on demand it even talks about how to download and get a specific file from a zip archive.
    http://msdn.microsoft.com/en-us/library/cc189021(VS.95).aspx
    Besides,  if you want to list the files,you could check articles below:
    http://blogs.msdn.com/b/blemmon/archive/2009/11/25/reading-zip-files-from-silverlight.aspx
    Best Regards,
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Extract the zip files

    Hi,
    I want to upload and extract the zip files. However I am able
    to upload the zip file but not able to unzip it after uploading. Is
    it possible in coldfusion mx 7. I know its possible in coldfusion
    8, but I need solution in version 7. Please let me know if there is
    any free components or third-party API's.
    Thanks!

    as you know cf mx 7 does not have a built-in zip
    functionality.
    you will have to install a zip application (i.e. 7zip, which
    is free) on
    your server and use cfexecute to run it and unzip your file.
    if you are on a shared hosting you are pretty much out of
    luck - look if
    your server has a pre-installed php or other script to manage
    zip
    archives...
    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/

  • Zipping multple files and sending the Zipped folder to target location using Biztalk

    Hi all,
    I have requirement like
    Seperate Xml files will be coming as incoming message to Biztalk
    Biztalk need to send a zipped folder contining all these xml to target location
    any link or component i can use to meet this requiremant  plese help
    regards,
    Vineeth

    Create or use the publicly available custom component for unzipping the received message and for send use another component to replace all attachments of a multi-part message
    (multiple parts to multiple files to zip) for its zipped equivalent. If not multiple message use any zipping API to zip the multiple 
    files to zip file and send the zipped file in send port.
    BizTalk Pipeline Custom Component Message Unzippper
    Zip Files in a Custom Pipeline Component
    Multi-Part Message Attachments Zipper Pipeline Component
    BizTalk Multipart Message Attachments Zipper is a pipeline component
    List of custom Pipeline component you can use
    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply.

  • I need help. My ipad 2 was stuck in recovery mode. i tried to connect it to itunes and restore but after downloading the file and extracting the software there is a pop up message that says "the device is full" i dont know what to do. Its been 2 days now.

    I need help. My ipad 2 was stuck in recovery mode. i tried to connect it to itunes and restore but after downloading the file and extracting the software there is a pop up message that says "the device is full. Deleting files and emptying your recycle been will help you restore." how am i going to erase files if i can't open my ipad. i dont know what to do. Its been 2 days now. please help. thanks.

    yes i am sure. This are the exact words... "The iPad "iPad" could not be restored. The disk you are attempting to use is full. (Removing files and emptying the recycle bin will free up additional space". i tried some options, hard reset, redsnow, tinyumbrella but still it's stuck.

  • FSCM MP9 - unable to extract the zip file EODS_QUERY_FIX

    Hi,
    I am applying FSCM 9.1 Maintenance Pack 9 on Finance application.
    During on estep I need to apply the project, which can be found on EODS_QUERY_FIX.ZIP
    "Please locate EODS_QUERY_FIX.zip in upd878541\upd878541_install and manually apply the project to your Database."
    I am unable to extract the zip file.
    It's high appreciated if some one can help me in extracting or identifying the project.
    Thank You!
    Best Regards
    Soundappan

    Hi,
    I had the same exact issue yesterday. From my install workstation I was unable to open the zip file but from another PC I could open it with no errors, so I've copied the archive I could open from my PC to my install workstation and still I could not open it.. very strange.
    The difference between my PC and the install workstation was that on my PC I'm using 7zip and on the install workstation I'm using WinZip.
    So I've extracted the zip file with 7zip on my PC then, still on my PC I've recreated a new zip file, transferred this to the install workstation and finally I could open it!
    Hope this helps

  • How can I read the bootstrap files and extract the fragment-URLs and fragment-numbers in plain text?

    How can I read the bootstrap files of any HDS Live stream and extract the fragment-URLs and fragment-numbers in plain text?
    Could it be that it is some kind of compressed format in the bootstrap? Can I uncompress it wirh  f4fpackager.exe? Could not find any download for f4fpackager.exe. I would prefere less code to do so. Is there something in Java of JavaScript, that can extract the fragment-numbers?
    Thank you!

    Doesn't sound too hard to me. Your class User (the convention says to capitalize class names) will have an ArrayList or Vector in it to represent the queue, and a method to store a Packet object into the List. An array or ArrayList or Vector will hold the 10 user objects. You will find the right user object from packet.user_id and call the method.
    Please try to write some code yourself. You won't learn anything from having someone else write it for you. Look at sample code using ArrayList and Vector, there's plenty out there. Post in the forum again if your code turns out not to behave.

  • How to upload a PDF file, zip it and download the zipped file?

    Hi Experts,
    I have a requirement to upload a PDF file, convert that to a ZIP file and download it. If anyone has worked on this requirement, can you please guide me on this? Thanks.
    Avi

    Here you go.  Hope it helps.
    REPORT  zrich_0004.
    DATA: lt_data TYPE TABLE OF x255.
    DATA: ls_data LIKE LINE OF lt_data.
    DATA: lv_zip_content TYPE xstring.
    DATA: lv_size  TYPE i.
    DATA: lv_filename TYPE string.
    DATA: lv_path TYPE string.
    DATA: lv_fullpath TYPE string.
    DATA: lt_filetab TYPE TABLE OF file_table.
    DATA: ls_filetab LIKE LINE OF lt_filetab.
    DATA: lv_rc TYPE sy-subrc.
    DATA: lv_content TYPE xstring.
    DATA: lo_zip TYPE REF TO cl_abap_zip.
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    PARAMETERS: p_up TYPE string DEFAULT 'C:\upload.pdf' .
    PARAMETERS: p_down TYPE string DEFAULT 'C:\download.zip' .
    SELECTION-SCREEN END OF BLOCK b1.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_up.
      REFRESH lt_filetab. CLEAR ls_filetab.
      cl_gui_frontend_services=>file_open_dialog(
          CHANGING
            file_table              = lt_filetab
            rc                      = lv_rc
        EXCEPTIONS
          OTHERS                  = 5 ).
      READ TABLE lt_filetab INTO ls_filetab INDEX 1.
      IF sy-subrc = 0.
        p_up = ls_filetab-filename.
      ENDIF.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_down.
      CLEAR: lv_filename, lv_path, lv_fullpath.
      cl_gui_frontend_services=>file_save_dialog(
         CHANGING
           filename             = lv_filename
           path                 = lv_path
           fullpath             = lv_fullpath
         EXCEPTIONS
           OTHERS               = 4 ).
      p_down = lv_fullpath.
    START-OF-SELECTION.
      CREATE OBJECT lo_zip.
    * Read the data as a string
      cl_gui_frontend_services=>gui_upload(
        EXPORTING
          filename                = p_up
          filetype                = 'BIN'
        IMPORTING
          filelength = lv_size
        CHANGING
          data_tab                = lt_data
        EXCEPTIONS
          OTHERS                  = 19 ).
    * convert binary to xstring
      CLEAR lv_content .
      CALL FUNCTION 'SCMS_BINARY_TO_XSTRING'
        EXPORTING
          input_length = lv_size
        IMPORTING
          buffer       = lv_content
        TABLES
          binary_tab   = lt_data
        EXCEPTIONS
          failed       = 1
          OTHERS       = 2.
    * Get the file name of the uploaded file
      DATA: lv_upfilename TYPE string.
      DATA: lv_tmp TYPE char1024.
      DATA: lv_tmp_file TYPE char1024.
      lv_tmp = p_up.
      CALL FUNCTION 'STRING_REVERSE'
        EXPORTING
          string  = lv_tmp
          lang    = sy-langu
        IMPORTING
          rstring = lv_tmp.
      SPLIT lv_tmp AT '\' INTO lv_tmp_file lv_tmp.
      CALL FUNCTION 'STRING_REVERSE'
        EXPORTING
          string  = lv_tmp_file
          lang    = sy-langu
        IMPORTING
          rstring = lv_tmp_file.
      lv_upfilename = lv_tmp_file.
    * add to zip file.
      lo_zip->add( name = lv_upfilename content = lv_content ).
      lv_zip_content   = lo_zip->save( ).
    * Conver the xstring content to binary
      CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
        EXPORTING
          buffer        = lv_zip_content
        IMPORTING
          output_length = lv_size
        TABLES
          binary_tab    = lt_data.
    * download
      cl_gui_frontend_services=>gui_download(
          EXPORTING
            bin_filesize = lv_size
            filename     = p_down
            filetype     = 'BIN'
          CHANGING
            data_tab     = lt_data
          EXCEPTIONS
            OTHERS       = 24 ).
    Regards,
    Rich Heilman

  • How to create a self-extracting downloaded Zip file ...

    I have a question about Mac file compression for an eBook PDF.  I know how to compress the file with Mac OS X 10.8.5.  I right-click the PDF I want to compress and select "Compress <file name>" from the Contextual Menu.  The file is compressed as a ZIP file.  The file I'm compressing will be distributed from a web server to Mac users.
    SITUATION:  I want the Mac user to be able to download the ZIP file to their Mac.  Once the ZIP file is downloaded to their Mac, I want the ZIP file to automatically open to place the eBook PDF on their desktop - so please indulge me here.  I know that a Mac user only needs to double-click the ZIP file to extract the eBook PDF, BUT, IF POSSIBLE, I want this to happen automatically after the ZIP file is downloaded.
    QUESTION:  Is there any way to automatially extract the eBook PDF from the ZIP file once the Mac user downloads the ZIP file to their destop?  If so, how do I do this?  If not, is there anyother way to do this that does not required any additional software like StuffIt Expander to decompress the file?  As an aside, If I compress the eBook PDF using Mac OS X 10.8.5, is this compressed ZIP file compatible with older versions of Mac OS, i.e., can they double-click the compressed ZIP file to open it?
    Thank you in advance for your comments and help . . .
    Jim Minor
    Email: [email protected]

    In OSX, zip extraction depends on the browser and browser settings. For example, Safari will open files automatically depending on this setting in Sarari Preferences: So the short answer I think is no. Your zip recipients are going to have to click on the zips to open them if their browser is not set to open them automatically.
    I'm no zip expert but I would think a zip is a zip and should be compatible with older versions of OSX. That is, 10.4 or later, which didn't include Stuffit any more. Earlier versions would need Stuffit or something similar.

  • How can I get a preloader to launch a main (external) swf file, and have the main file remove the preloader once it's fully loaded?

    Using Flash MX, ActionScript 2:
    I’ve been struggling for several weeks, trying to get a preloader to work on a large (~80 MB) photo portfolio file (using the method where the preloader is on frame 1 of the file, and when loading is completed, it jumps to the content).  I’ve done countless tutorials, and none seem to work on my presentation.  I even tried downloading a trial version of CS4 so I could export every one of the file’s library movie clips and images so that they load on Frame 2 (a feature MX doesn’t have).  It takes about 20 seconds for the .exe to load from a CD, and no matter which preloader construction I use, it always seems to appear in the last few seconds before the movie loads completely.  During the initial wait time, there’s no indication that anything is happening:  no hourglass on the mouse, and not even a blank screen. This is only true for the first time that the file is loaded from the CD; on subsequent loads, the file must already be in RAM, because it loads within a few seconds. 
    I decided that I’m going to try and make the file which the user clicks on (one named Windows_Portfolio.exe or another called Mac_Portfolio.hqx) the preloader so that it would be tiny, and would load instantly.  I want that file to launch the external huge portfolio file (renamed files.swf), keep track of its loading progress, and cycle through a slideshow (10 thumbnail images that transition into each other over 100 frames) proportionally, based upon the percentage of files.swf that had been loaded.
    I assume that there should be a loadMovie() or a loadMovieNum() command on the preloader’s timeline to launch files.swf, and that the initial code of files.swf should have some sort of this._parent._visible=false or other way of deleting the preloader on level0.  Can anyone explain the steps to me, or direct me to a good Flash MX tutorial that explains how to launch another external swf from a preloader .exe, keep track of its load progress, and delete the preloader .exe once the external swf had been loaded?
    Also, I’ve read that, using this construction on a CD, every file has to be in the same place, and that I can’t nest files.swf in a folder named “files,” and reference it with files/files.swf.  Is this true?
    Thanks for any assistance you can offer.

    If you know JavaScript (ECMA Script) then you might be able to get it done applying a for loop and a random function
    to the for loop if you know how to get a page-loaded request into JavaScript.
    But an easier solution, if you know ActionScript 3.0, and if your SWF's don't need to be recoded and can load into a "container" SWF would be to create a master FLA file that loads your SWF's in a random fashion using Math.random() as a multiplier, though you won't see much variation if you only have 2-3 SWF's to load--if you had more than that then you would begin to benefit from the random function's capabilities.  In ActionScript 3.0 use the load() method along with addChild() to load the SWF and add it to the stage.  You will be able to search for specifics on how to code the FLA properly by using Flash's Adobe Help tool and also using an internet search.
    -markerline
    P.S. Once you have the master FLA coded you can Publish it to an SWF and an HTML and if the container/master SWF needs to be in a page with other content you can simply copy and paste the object and embed tags for the container SWF from the published HTML into any place on your master HTML that you need it to reside.  You can then use CSS to control placement of the SWF object if it is in a div tag.

  • How do I create and send a zip file? I have Lion and I'm working in Word for mac

    To show you how little I know about any of this, I don't even know if this is the correct forum in which to ask this question. I'm a copywriter. I have a client in France. I have 15 word documents, 15 of the same documents in PDFs and a small Excel document to send him. Simple, mutlipage Word docs. Short two-page Excell sheet. I want to create a zip file for them to send to him. Can I do it? How? I have unzipped zip files other people have sent to me, but I've never created or sent one myself. I'm working in Word for Mac 2011. I have Lion. I'm using Mac's email. Please don't assume I know anything. I need very, very simple, play by play instructions. You are all very helpful, so I have high hopes.
    Nancy

    Visit:
    http://download.cnet.com/MacZip/3000-2250_4-10025248.html
    You will be able to both zip and unzip. If the recipient of your zipped file does not have zip, he/she will need to get it, or you could send him/her the above address so that he/she can unzip his/her file.
    (I wish the English language could settle on the use of something less clumsy that he/she him/her etc.)
    BTW, I think that you can zip only folders, not separate files, so put even one file into a folder before zipping).
    Message was edited by: SteveKir Added BTW

  • How to open a file and display the complete file path?

    In my script, I want to create a dialog that prompts the user to define a few variables for the script. One of those variables is the path to a template file. I want it to work the same way that an upload form works. You click the browse button, the dialog appears so that you can browse for the file and then when you click OK or Open, the full path of the file is displayed in the text box next to it. How do I do this with JavaScript? I got this far and it seems to be working, but the wrong text is being displayed in the text box. Plus: How do I properly restrict the file types to PSD. The code doesn't seem to work, despite the fact that there are no errors reported. Initially the Text box is blank, but After I browse for the file, the text box says: "File". Here is the problem area:
    defineVars.STPnl.STBrowse.onClick = function browseST() {
    var stbFile = File.openDialog("Select the Single Mugshot Key Template File", "File Types: *.psd, *.PSD");
    defineVars.STPnl.STPath.text = stbFile;
    Thank you to whoever assists me! :)

    Change this:
    defineVars.STPnl.STPath.text = stbFile;
    To this:
    defineVars.STPnl.STPath.text = stbFile.fullName;
    The reason is that stbFile is a File object, you need to access its properties in order to get the full path.

  • How do I work on my raw files and not the jpeg files that currently dispaly

    When I launch Aperture my pictures display in jpeg format, I do however take all my pictures in both raw and jpeg. How do I convert and work on the raw files? Is my interpretation that I am working on my Jpeg files correct?
    My thanks for any help provided.

    The preference to import both and use RAW vs. JPEG as master can be set on import and you can convert on a project-by-project basis.
    You can tell what Aperture is using a few different ways. If you select the meta-data tab then show the "File Info" (the pull-down menu) it'll show you exactly which file it's using as the master.
    Also if you right-click over the mouse you'll see one of the pop-up menu options to "Set JPEG as Master" or "Set RAW as Master" (it'll show whichever one you aren't using -- so if it offers to "Set RAW..." then that means it's currently using JPEG.
    To convert a whole project, it's as gocuk says in the reply above.... select the "Library" tab at left, make sure you highlight the Project you want to convert, then in the menubar pick "Photos" -> "Switch Project to use RAW as Masters" (which will only be bold and selectable if it's currently set to use JPEG).

  • I need program to extract the zip file

    Please help me to chose the better program extract zip file from web page or email.
    Thanks

    http://osxdaily.com/2013/05/13/open-zip-files-iphone-ipad/
     Cheers, Tom

  • How to read spool file and get the spool file number

    Hey everyone.
    I created a program ztemp that is calling another program ztemp2 within, ztemp2 creates a spool file. Now the requirement is I need to write a code within ztemp to download that spool request and then convert it to the pdf file. I know I can use program rstxpdft4 to convert the spool file to the PDF but for this I need to give the spool number, so can you please tell me how can I get the spool number and then fetch it to the program rstxpdft4 .
    Thank you.
    Rhul goel

    Hi,
       Please check the [link|Convert ABAP List to PDF and display without downloading first; (Rich's reply) and get the spool similarly.
    Or read from table TSP01 to get the latest spool using sy-uname.
    Regards,
    Srini.

Maybe you are looking for

  • XML Elements Ordering in Generated XML Output

    I have a requirement where I need the xml element tags to appear in the generated xml output in the same order as in data template definition but in my case this is not happening. I have one master group - Customer and two subgroups - BillingAddress

  • Could soap return a xml to client?

    Hi everyone: I want to know whether soap could return client a xml document. I mean that I want to display a xml to client's Browser after client invoke a soap method. It is possible? But I don't want to create a xml in the server because it shouldn'

  • Vista Problem Since 2.0.2

    I'm having a problem with my Vista computer and my Apple TV. Since I updated to the 2.0.2 firmware on the ATV. It worked fine on 2.0 firmware. The Apple TV doesn't disappear from iTunes like other people have been saying. The ATV still seems to lose

  • Shortcut keys in id tags info panel

    Is there a key(s) [or a way to set a key(s)] to move to the next tune when editing id tags?

  • I get an error message -50

    Trying to update to iOS 5 and my pc stops and gives me error iTunes -50 n to continue it'll delete my phone info.