How to unzip and zip using DLL?

xPass

All aboard the xPass Express!
Reaction score
26
Hi guys! Yes it's me again...

New question today:
"How to unzip and zip using DLLs?"

I'm basically making a Warcraft III Version Switcher (which you might know) and I have used before Ugge's WVS. I see that there is no need for the user to unzip the version's files and Ugge used an unzip and a zip dlls, but I don't see how does he use it.

You see, the version's files are all zipped and when unzipped, are used to overwrite the existing files (from what I can gather), but the problem is how do I unzip it and overwriting the files when I want it to self extract when a button is clicked?

If you ever have had a chance to use Ugge's wvs, you will know that when he made the tool this way that when a user clicks the version he/she want's to switch to, the files will automatically be unzipped and overwrites the existing files.

I know he uses the DLL, but the whole point is still back to this question:
How do I unzip (nevermind zip) a zipped archive using a DLL?

I know I'm very noob, so if you need to know, I'm using AHK (AutoHotkey, google it). :D I hope you can help me! Until then, HAVE A GOOD DAY :D
 
ahk, i don't know what language it's using, all i know is it uses notepad to code
 
I think it's a simplefied Visual Basic/C# combination... If you're able to create a script that executes a executable, then you could use the .Net Framework and use this example.
 
I think it's a simplefied Visual Basic/C# combination... If you're able to create a script that executes a executable, then you could use the .Net Framework and use this example.

Err thanks, but I'm not really good in programming, so will you please simplify it for me pls thx :D
 
I don't think you will be able to make what you want using that. Use a proper programming language, such as C# and use the .NET framework as MusicDemon said.
 
You have to call the functions that do that zipping and unzipping from the dll. You will do that in code. If you can find the code that actually does this in a working game your best chance would be try to modify that code to do what you want as it will be working. The dll cannot execute, it just has functions available that you can reference in your code.
 
Oh man! So I cannot unzip the files now can I? >.<

Edit:
Wait, there is this function:
Result := DllCall("[DllFile\]Function" [, Type1, Arg1, Type2, Arg2, "Cdecl ReturnType"])

from here:DllCall()

any ideas how to call the functions for unzipping?

Edit2:
Gosh I'm seriously frustrated for wasting so much time looking for the solution of unzipping without progress!

Okay, let's say it this way:
I need something (DLL or not) that can extract zipped archives!! Somebody help me please or I think I'm going crazy! :banghead:
 
That DLL call would probably work, however a DLL is simply a file which contains functions which make life easier. I'm guessing you don't have a DLL whose purpose it to unzip files.

Unless you can find a DLL that does it for you, then you would have to create one yourself.
 
That DLL call would probably work, however a DLL is simply a file which contains functions which make life easier. I'm guessing you don't have a DLL whose purpose it to unzip files.

Unless you can find a DLL that does it for you, then you would have to create one yourself.

Wow, thanks! But since I do not have the knowledge of DLL , can you make one that can unzip files for me? or even better: TEACH ME :D Well, a guide can be useful...

Hmm... so what you basically mean is that AHK can call functions from ANY dlls?
 
Here is some useful code on unzipping in the .NET framework. You could port this into a dll.
 
Wait, before I read, firstly thanks. Secondly, after I am done with the code, do I save it with .dll extension and put the icon?

Edit:
Err wait, how do I call these functions while using AHK?

Edit2:
OMG! I can't believe this! I don't understand it at all T_T I need some help here! Somebody make me an unzip DLL and tell me what to do for the dllcall() for your dll please! I'll give you credits in the program in the About button!!!!! PLEASE!!!!!!!!!!
 
To create a dll from that code, you would need to use a program such as Visual C# and create a Dynamic Link Library file. Never done it before, but I'm presuming you can then just reference to it like a normal class file.
 
To create a dll from that code, you would need to use a program such as Visual C# and create a Dynamic Link Library file. Never done it before, but I'm presuming you can then just reference to it like a normal class file.

Lol, then I'm doomed :D The newest Visual C# don't work with Windows XP Service Pack 2, does it? Well, but I just don't understand all those reference guides... I am in need of someone who can write up an unzip-able dll file and can give me the code for calling the unzip function using AHK's dllcall() function. :(
 
Then get an older version. I know 2010 works on 32-bit OS's (can't remember if there's separate 62 and 32 bit versions), I have it on a computer with XP. I have SP3 though.
 
Then get an older version. I know 2010 works on 32-bit OS's (can't remember if there's separate 62 and 32 bit versions), I have it on a computer with XP. I have SP3 though.

Yeah, a lot of programs are limited to SP2. Many works only on SP3 and above... By the way, what's 62 and 32 bit? I've been seeing it for ages yet can't find out what it means lol...
 
64 is the newest (best), with most computers coming with it today, though I would say 32 bit is still more common.
 
32 bit systems are typically limited to 4 gigs of RAM. 64 allows for up to 128 gigs of RAM (Home Versions are only like 8 or 16 I think). That being said, there are VERY few things that I need upwards of 4 gigs for at this point, let alone 128, even in game development I rarely use that much. Things like giant ass workstations would use that.
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    News portal has been retired. Main page of site goes to Headline News forum now
  • The Helper The Helper:
    I am working on getting access to the old news portal under a different URL for those that would rather use that for news before we get a different news view.
  • Ghan Ghan:
    Easily done
    +1
  • The Helper The Helper:
    https://www.thehelper.net/pages/news/ is a link to the old news portal - i will integrate it into the interface somewhere when i figure it out
  • Ghan Ghan:
    Need to try something
  • Ghan Ghan:
    Hopefully this won't cause problems.
  • Ghan Ghan:
    Hmm
  • Ghan Ghan:
    I have converted the Headline News forum to an Article type forum. It will now show the top 20 threads with more detail of each thread.
  • Ghan Ghan:
    See how we like that.
  • The Helper The Helper:
    I do not see a way to go past the 1st page of posts on the forum though
  • The Helper The Helper:
    It is OK though for the main page to open up on the forum in the view it was before. As long as the portal has its own URL so it can be viewed that way I do want to try it as a regular forum view for a while
  • Ghan Ghan:
    Yeah I'm not sure what the deal is with the pagination.
  • Ghan Ghan:
    It SHOULD be there so I think it might just be an artifact of having an older style.
  • Ghan Ghan:
    I switched it to a "Standard" article forum. This will show the thread list like normal, but the threads themselves will have the first post set up above the rest of the "comments"
  • The Helper The Helper:
    I don't really get that article forum but I think it is because I have never really seen it used on a multi post thread
  • Ghan Ghan:
    RpNation makes more use of it right now as an example: https://www.rpnation.com/news/
  • The Helper The Helper:
  • The Helper The Helper:
    What do you think Tom?
  • tom_mai78101 tom_mai78101:
    I will have to get used to this.
  • tom_mai78101 tom_mai78101:
    The latest news feed looks good
  • The Helper The Helper:
    I would like to see it again like Ghan had it the first time with pagination though - without the pagination that view will not work but with pagination it just might...
  • The Helper The Helper:
    This drink recipe I have had more than a few times back in the day! Mind Eraser https://www.thehelper.net/threads/cocktail-mind-eraser.194720/

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top