Solved

ZIP FILE/DIRECTORY WITH PASSWORD

Posted on 2013-06-25
15
298 Views
Last Modified: 2013-07-04
Hi All,

I want to zip file/directory with password.

How could I do it ?

Thank you.
0
Comment
Question by:emi_sastra
  • 7
  • 5
  • 3
15 Comments
 
LVL 12

Accepted Solution

by:
mwochnick earned 300 total points
ID: 39276914
Utilize SharpZipLib
http://www.icsharpcode.net/OpenSource/SharpZipLib/Default.aspx


There's an example using SharpZipLib first in C# then in VB
https://github.com/icsharpcode/SharpZipLib/wiki/Zip-Samples
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39276930
Hi mwochnick,

Is there any native from VS ?

Thank you.
0
 
LVL 12

Assisted Solution

by:mwochnick
mwochnick earned 300 total points
ID: 39276972
you could look at the ZipArchive class in .NET 4.5, but I'm not sure if it has a password capability.
http://msdn.microsoft.com/en-us/library/system.io.compression.ziparchive.aspx
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39277008
Ok.

If I use 3rd party zip, what should I copy to client computer ?

Could we use rar to do so, zip and password using VB Code ?

Thank you.
0
 
LVL 12

Expert Comment

by:mwochnick
ID: 39277923
you should be able to use any of the zip clients that support the zip format.
Winzip
7zip
etc
0
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39278178
With a 3rd party DLL, you can deploy this DLL as part of your application so it would work on client computers. With a program like RAR, this program will be required to be installed on client computers if you need to zip/unzip from your program so DLL is the way to go in my opinion.
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39278398
Hi CodeCruiser,

- if you need to zip/unzip from your program so DLL is the way to go in my opinion.
If I use rar, what dll do I need ?

Thank you.
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39278481
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39278508
Where is the dll file reside ?

Do I have to add it to references ?

Thank you.
0
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39279496
Yes. It will reside in same folder as your program.
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39295367
I am sorry, just back.

-Yes. It will reside in same folder as your program.
I mean where is the dll of the 3rd party rar and what is the name ?

Thank you.
0
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39297332
Any particular reason for using rar? Free zip libraries can easily be downloaded. I have not seen many for rar (there is a paid chilkot component).
0
 
LVL 1

Author Comment

by:emi_sastra
ID: 39298753
-Any particular reason for using rar? Free zip libraries can easily be downloaded. I have not seen many for rar (there is a paid chilkot component).
No, I meant any zip libraries. I've never noticed the dll from zip librariy. Usually I just install and use it. Where is the dll reside and what is its name to be used inside VB ?

Thank you.
0
 
LVL 83

Assisted Solution

by:CodeCruiser
CodeCruiser earned 200 total points
ID: 39300096
It would reside in GAC if its not in your bin folder. It should also be in program files folder of that library.
0
 
LVL 1

Author Closing Comment

by:emi_sastra
ID: 39301047
Hi All,

Thank you very much for your help.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now