Solved

Create RAR File using .Net

Posted on 2013-05-20
29
2,642 Views
Last Modified: 2013-05-28
I want to Create RAR File using  .Net (no Rar.exe or WinRar.Exe)


thanks

Kalpesh
0
Comment
Question by:Kalpesh Chhatrala
  • 14
  • 7
  • 3
  • +2
29 Comments
 
LVL 42

Expert Comment

by:sedgwick
ID: 39180359
sharpcompress - here's open source from codeplex (.net 3.5/4):
http://sharpcompress.codeplex.com/releases/view/98965
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39180364
SharpCompress only Extract RAR File. i want to create RAR File.
0
 
LVL 19

Accepted Solution

by:
Rikin Shah earned 250 total points
ID: 39180396
Hi,

Rar is proprietary. Why do you stick to rar, there are other other formats, where you can make your own implementation without restriction.

If you still want to work on Rar then you will need to use winrar.exe

Rar is not free- http://en.wikipedia.org/wiki/RAR
You can go for 7-zip- http://www.7-zip.org/sdk.html
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39180484
i know RAR is Proprietary File Format. i am also using other format.

but i required RAR Solution without WinRar.exe
0
 
LVL 78

Assisted Solution

by:David Johnson, CD, MVP
David Johnson, CD, MVP earned 250 total points
ID: 39180487
Can't be done without access to the proprietary algorithms or an API
0
 
LVL 10

Expert Comment

by:Monica P
ID: 39181042
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39181100
I want to Create RAR File in .Net (Not Zip File).

your solution is for .Zip File
0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39181228
Hi,

You neither want to use Rar nor winrar!

The only option here is to contact winrar team- http://www.rarlab.com/wgmbh.htm
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39181253
I knew this solution. i already tell in my Question. i don't want to use RAR and WinRAR

i required .Net Library.
0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39181289
Hi,

There is none available. That's why I ask you to contact winrar team.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193282
I've requested that this question be deleted for the following reason:

did not get any solution.
0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39193283
There is no solution... Best suggestions were provided! Auther just want to use a paid tool service without using the it.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193289
i asked .Net Solution Not WinRar / RAR. i already cleared in My Question.
0
DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193291
I've requested that this question be deleted for the following reason:

Did not get Solution as per my question.

0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39193292
And that is what I cleared in my answer... There is no solution available.
0
 
LVL 78

Expert Comment

by:David Johnson, CD, MVP
ID: 39193310
There is BUT not with .net you have to contact the programs author since it is a proprietary algorithm and the author likes to get paid. Sometimes the correct answer is that there is NO answer and we will keep objecting until you understand this.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193325
I asked clearly in MyQuestion.

i required .Net Solution then why are you wasting my time ?
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193627
I've requested that this question be deleted for the following reason:

Please Delete this Question.  i did not get solution as per my question.
0
 
LVL 78

Expert Comment

by:David Johnson, CD, MVP
ID: 39193628
I am not wasting your time. Sometimes the answer is NOT what you want i.e. It Can't be Done is an acceptable answer.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193639
    Private Sub RemovePassword(Filename As String, Password As String)
        Dim WinrarPath As String = "C:\Program Files\WinRAR\WinRAR.exe" 'Could put in configuration.
        Dim ExtractCmd As String = String.Format("X -p{0} *.* C:\temp\extract\", Password)

        Dim p = Process.Start(WinrarPath, ExtractCmd)
        p.WaitForExit()
        'Rename old rar file as .old
        IO.File.Move(Filename, Filename & ".old")

        Dim RecreateCmd As String = String.Format("A ""{0}"" C:\temp\extract\*.* -ep1", Filename)
        p = Process.Start(WinrarPath, RecreateCmd)
        p.WaitForExit()


    End Sub

Open in new window

0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193793
I've requested that this question be closed as follows:

Accepted answer: 0 points for kalpesh2804's comment #a39193639

for the following reason:

i forcefully accepted this code as answer.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39193650
Please Delete this Question.  because i did not get solution as per my question.
0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39193794
What Kalpesh has answered was not exactly the question... He has clearly mentioned that winrar.exe or rar.exe should not be used.

Hence, the answer is not acceptable.
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39194032
I've requested that this question be deleted for the following reason:

i want to delete the question.

0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 39198592
Kalpesh does not want to assign any answer as a solution.

I would ask the moderators do the right job and assign the points to right answer.

Rikin
0
 
LVL 16

Author Comment

by:Kalpesh Chhatrala
ID: 39198597
I will not select any Answer. because i did not get answer.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Excel file not created as expected 7 46
Class object 2 26
Syntax error 9 45
Write to file when application closes (by logoff) - VB.NET 1 13
It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
Concerto provides fully managed cloud services and the expertise to provide an easy and reliable route to the cloud. Our best-in-class solutions help you address the toughest IT challenges, find new efficiencies and deliver the best application expe…

930 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

14 Experts available now in Live!

Get 1:1 Help Now