Please find this little part of code :
 
REBOL []
fsplit: get in context
[   fsplit: func
    [   {split the file in files with names root-name1 root-name2 ...
         of block-size length.
        }
        file
        root-name
        block-size
        /local
            source-file data destination-file file-count file-name
    ]
    [   file-count: 0
        source-file: open/read/binary/direct/no-wait file
        while [data: copy/part source-file block-size]
        [   file-count: file-count + 1
            file-name: rejoin [to-file root-name file-count]
            destination-file: open/write/binary/direct file-name
            insert destination-file data
            close destination-file
        ]
        close source-file
    ]
] 'fsplit
; fsplit c:\winzip.log "winziplog" 16384
; split winzip.log file in files winziplog1 winziplog2 ... of 16Kb length
 
Hope this help !
-yos

Marcelo Fontes Castellani <[EMAIL PROTECTED]> wrote:

Hi guys

I need to upload an file to my FTP site but I need to divide this file in
multiple files. For example, if file have 2048 KB I need to divide it in 2
(1024 and 1024).

I can do it with Rebol, ok ? If I can, how can I do ?...

Thanks and a hug...

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.



---------------------------------
Do You Yahoo!? -- Avec Yahoo! soyez au coeur de la récolte de dons pour le Téléthon.

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to