• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

compress a file with gzip

#2
I don't have access to *nix now, but could you try ... OS-COMMAND SILENT VALUE(vGZIPCommand).
where vGZIPCommand is your gzip command (ex: gzip -c myfile > myzipfile.gz) ?
 
#3
Hello, I did not use GZIP but this may serve as a guide you:

[TABLE="class: outer_border, width: 500"]
[TR]
[TD]DEFINE VARIABLE c-file1 AS CHAR.
DEFINE VARIABLE c-file2 AS CHAR.


c-file1 = "C:\TEMP\citivta.zip".
c-file2 = "C:\TEMP\citivta.txt".


OS-COMMAND SILENT VALUE("z-rar.bat " + c-file1 + ' ' + c-file2).
[/TD]
[/TR]
[/TABLE]

Generate a batch file (z-rar.bat) as follows.

[TABLE="class: outer_border, width: 500"]
[TR]
[TD]@echo off
set OLDPATH=%PATH%
set PATH=C:\Archivos de programa\WinRAR\;%PATH%
rar a -ep %1 %2
set PATH=%OLDPATH%
[/TD]
[/TR]
[/TABLE]

Regards.
 

RealHeavyDude

Well-Known Member
#5
Basically you can submit every OS command through the ABL using OS-COMMAND. You just need to be aware, especially on *nix systems, there might be security issues because the sub process started from the ABL to execute the OS command obviously can not elevate it's privileges.

Heavy Regards, RealHeavyDude.