Sign in to follow this  
Followers 0
jak

7-zip32.dll

75 posts in this topic

#1 ·  Posted (edited)

Functions for 7-zip32.dll

To hide the created window, you need to use -hide for the $cmdline parameter

The newest files and 7-zip32.dll are on my website now: http://www.jak-software.org/pub/autoit-stuff/7-zip/ (2006/10/14: Only 0.4 at the moment)

Newest Version: 0.4.1 (2006/10/15) [0.5 Alpha 1 Removed]

New in 0.4.1

7_zip32.dll

SevenZip_0_4_1.zip

Edited by jak

Share this post


Link to post
Share on other sites



It'is FANTASTIC!!!

WONDERFULL!!!

:)


Console Browse: Navigate on the WEB in a textual consoleMultiPing!: Show computer on the lan and/or show the local/remote task, ALL animated!KillaWin: Event executingCryptPage: Crypt your webpage and show only with key

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

As far as I know (correct me if I'm wrong) jak way is the only one to compress/crypt using an open source dll.

Anyway... congratulation, VERY useful.

Edited by masvil

Share this post


Link to post
Share on other sites

This could come in useful! Well done


My Programs:AInstall - Create a standalone installer for your programUnit Converter - Converts Length, Area, Volume, Weight, Temperature and Pressure to different unitsBinary Clock - Hours, minutes and seconds have 10 columns each to display timeAutoIt Editor - Code Editor with Syntax Highlighting.Laserix Editor & Player - Create, Edit and Play Laserix LevelsLyric Syncer - Create and use Synchronised Lyrics.Connect 4 - 2 Player Connect 4 Game (Local or Online!, Formatted Chat!!)MD5, SHA-1, SHA-256, Tiger and Whirlpool Hash Finder - Dictionary and Brute Force FindCool Text Client - Create Rendered ImageMy UDF's:GUI Enhance - Enhance your GUIs visually.IDEA File Encryption - Encrypt and decrypt files easily! File Rename - Rename files easilyRC4 Text Encryption - Encrypt text using the RC4 AlgorithmPrime Number - Check if a number is primeString Remove - remove lots of strings at onceProgress Bar - made easySound UDF - Play, Pause, Resume, Seek and Stop.

Share this post


Link to post
Share on other sites

Wasnt this done already a long time ago? lol except using xzip

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

From AutoIT v3.2.0 to last this dllcall crashes the script :-(

A confirmation is in the v3.2.0 History: "Changed: Fatal error message is now displayed if DLLCall cannot be executed."

Anyway if you use oldier than v3.2.0 all commands are executed and script stay stable; so maybe this error is not so "fatal" :-)

Any suggestion, workaround... ?

Edited by masvil

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

From AutoIT v3.2.0 to last this dllcall crashes the script :-(

A confirmation is in the v3.2.0 History: "Changed: Fatal error message is now displayed if DLLCall cannot be executed."

Anyway if you use oldier than v3.2.0 all commands are executed and script stay stable; so maybe this error is not so "fatal" :-)

Any suggestion, workaround... ?

Try Version 0.4.1 RC1, this should fix the problem. (I have not tested it, because I'm not using Windows at the moment.) Edited by jak

Share this post


Link to post
Share on other sites

I think you should have a Dll Handel parameter for the functions so you don't have to modify the code if you have it in like, the TEMP dir. Great work though.

Share this post


Link to post
Share on other sites

#10 ·  Posted (edited)

I think you should have a Dll Handel parameter for the functions so you don't have to modify the code if you have it in like, the TEMP dir. Great work though.

I'm currently working on version 0.5 of the functions, and there you will be able to specify the path of the dll. (Edit 15 Oct 2006: We will need Dll Handle from DllOpen for the functions in 0.5)

At the moment: To use the 7-zip32.dll ín your temp folder you could add the following to the top of your script:

EnvSet("PATH", @TempDir & ";" & EnvGet("PATH"))oÝ÷ Ú«¨µéÚoÝ÷ Û­«­¢+Ø}MÙ¹i¥Á
5 ÅÕ½ÐíµÑé¥ÀÅÕ½ÐìµÀìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìµÀìÀÌØí½±ÉÁÑ µÀìÅÕ½ÐìÀäÈì¡i¥ÁÁ¤ÀäÈìÅÕ½ÐìµÀìÀÌØíÍé9µµÀìÅÕ½Ðì¹é¥ÀÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìµÀìÀÌØí½±ÉÁÑ µÀìÅÕ½ÐìÀäÈìÅÕ½ÐìµÀìÀÌØí¥±1¥ÍÑlÀÌØí¥tµÀìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìÅÕ½ÐìµÀìÅÕ½Ð쵡¥ÅÕ½Ðì¤íÉÕ¸Ýé¥À½µµ¹±¥¹oÝ÷ Ù»­mëmz¼(ºW[y«­¢+Ù}MÙ¹i¥Á ÀÌØí½±ÉÁÑ µÀìÅÕ½ÐìÀäÈì¡i¥ÁÁ¤ÀäÈìÅÕ½ÐìµÀìÀÌØíÍé9µµÀìÅÕ½Ðì¹é¥ÀÅÕ½Ðì°ÀÌØí½±ÉÁÑ µÀìÅÕ½ÐìÀäÈìÅÕ½ÐìµÀìÀÌØí¥±1¥ÍÑlÀÌØí¥t°Ø°ÅÕ½Ðíé¥ÀÅÕ½Ðì°ÅÕ½Ð쵡¥ÅÕ½Ðì

and of course include SevenZip.au3 or Copy and paste the needed function to your code.

Edited by jak

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

_SevenZipAdd($folderpath & "\(Zipped)\" & $szFName & ".zip", $folderpath & "\" & $FileList[$i], 6 , "zip", "-hide")

Also I removed Version 0.4.1 RC1 (it did not work for me) and added 0.5 Alpha 1, which can be used the same way as before (or slightly different, see README.pdf in the archive) , should be faster and includes a modified version of Cue's script.

Edited by jak

Share this post


Link to post
Share on other sites

Thanks for making the necessary changes and including my script, much appreciated.

Share this post


Link to post
Share on other sites

0.5 Alpha 1, which can be used the same way as before (or slightly different, see README.pdf in the archive) ,

I'm testing it following readme.pdf instructions. I seems to works, but...

_SevenZipOpen()

<Your Script>

_SevenZipClose()

...it's not clear for me: have I to open and close before and after every single 7zip operation or, as it seems you mean, just one time? I'm asking it because if 2nd case AU3Check gives me following 3 errors:

- WARNING: $SevenZipDll: possibly used before declaration.

DllClose($SevenZipDll)

- WARNING: $SevenZipDll: declared global in function only. Prefer top of file.

global $SevenZipDll = DllOpen($dllfile)

- ERROR: SevenZipCMD(): undefined function.

Return SevenZipCMD('x ' & $sCMDLine & ' -o"' & $sOutDir & '" "' & $sArchive & '" "' & $sFilter & '"', $hWnd)

Share this post


Link to post
Share on other sites

#14 ·  Posted (edited)

I'm testing it following readme.pdf instructions. I seems to works, but...

_SevenZipOpen()

<Your Script>

_SevenZipClose()

...it's not clear for me: have I to open and close before and after every single 7zip operation or, as it seems you mean, just one time? I'm asking it because if 2nd case AU3Check gives me following 3 errors:

- WARNING: $SevenZipDll: possibly used before declaration.

DllClose($SevenZipDll)

- WARNING: $SevenZipDll: declared global in function only. Prefer top of file.

global $SevenZipDll = DllOpen($dllfile)

- ERROR: SevenZipCMD(): undefined function.

Return SevenZipCMD('x ' & $sCMDLine & ' -o"' & $sOutDir & '" "' & $sArchive & '" "' & $sFilter & '"', $hWnd)

I released Version 0.4.1, please use this one. Here you can simply use the functions _SevenZipCMD, _SevenZipAdd and _SevenZipExtract without calling other functions. You also should get no warnings.

I removed Version 0.5 Alpha 1, because I am going to rewrite all functions, add new ones and provide better documentation.

0.4.1 is stable now and everything works like version 0.4 with AutoIT 3.1.x

Edited by jak

Share this post


Link to post
Share on other sites

I released Version 0.4.1, please use this one.

I'm deeply testing it, will let you know.

In the while i wonder why there isn't more attention to this function while there are tons of thread about compression (almost zip) and crypting (idea and others): 7zip is open source and uses AES 256 bit, so in my opinion is the best way to go.

Thanx for effort :lmao:

Share this post


Link to post
Share on other sites

I'm deeply testing it, will let you know.

In the while i wonder why there isn't more attention to this function while there are tons of thread about compression (almost zip) and crypting (idea and others): 7zip is open source and uses AES 256 bit, so in my opinion is the best way to go.

Thanx for effort :ph34r:

Some of us are very limited on the approved freeware we are allowed to use at work.

Fortunately AutoIt is on the Approved list :lmao:


SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

I wonder if anyone has asked to add Zip functionality to AutoIt. I would be surprised if not.

Nice work though.

Share this post


Link to post
Share on other sites

Some of us are very limited on the approved freeware we are allowed to use at work.

Fortunately AutoIt is on the Approved list :lmao:

I know what you mean, but... why They say yes to AutoIT (potentially dangerous) and they say no to a compression open source dll to use with AutoIT?

Anyway 0.4.1 is stable.

@jak: why should I use Add or Extract instead of CMD for all commands/options?

Share this post


Link to post
Share on other sites

I know what you mean, but... why They say yes to AutoIT (potentially dangerous) and they say no to a compression open source dll to use with AutoIT?

Anyway 0.4.1 is stable.

@jak: why should I use Add or Extract instead of CMD for all commands/options?

We've been using autoit for 4 - 5 years, not only locally, but world wide.

And the Approved list rules went in affect just recently.


SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

Is there anyway to get a return code that let's you know if the extract was successful or not. It appears to me, and I maybe missing something, that it only returns a fail code if the dll fails to load. If you specify a wrong path to the archive, or there's a corrupted archive you get no indication of that.

I've tried running 7zip with runwait and don't seem to get the 7zip error codes returned either.

Thanks

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0