Click here to Skip to main content
15,888,461 members
Home / Discussions / C#
   

C#

 
AnswerRe: C# Classes Pin
Nouman Bhatti2-Sep-08 7:15
Nouman Bhatti2-Sep-08 7:15 
AnswerRe: C# Classes Pin
Mbah Dhaim2-Sep-08 9:50
Mbah Dhaim2-Sep-08 9:50 
GeneralRe: C# Classes Pin
#realJSOP2-Sep-08 9:59
mve#realJSOP2-Sep-08 9:59 
GeneralRe: C# Classes Pin
Mbah Dhaim2-Sep-08 10:11
Mbah Dhaim2-Sep-08 10:11 
QuestionErrorProvider icon disappear after fixing the error Pin
mahraja2-Sep-08 2:08
mahraja2-Sep-08 2:08 
AnswerRe: ErrorProvider icon disappear after fixing the error Pin
curtisk2-Sep-08 2:21
curtisk2-Sep-08 2:21 
GeneralRe: ErrorProvider icon disappear after fixing the error Pin
curtisk2-Sep-08 2:24
curtisk2-Sep-08 2:24 
QuestionWriting to the compression stream is not supported. Pin
tamour2-Sep-08 1:47
tamour2-Sep-08 1:47 
Dear all,
I have compressed files in a SharePoint Library through a SharePoint's Feature into another Library. Say the name of the first library is "My Document Store" and the library where the feature stores the documents after compressing is "Compressed Document Store". The feature runs after a specific time. Now the feature is working fine, I am using "System.IO.Compression" library to compress the documents. Secondly, i have made a webpart, which displays the compressed document list. What i want to do is when a user clicks on a compressed document, the document should be uncompressed on the fly and should become downloadable to the user. But the point where i am stuck is, when i try to decompress the document, i.e,

 use   //FileStream fs = File.Create(Server.MapPath("~") + "/tv1.xml");
 any   //MemoryStream fs = new MemoryStream();
stream //SPFileStream fs = new SPFileStream(web, 204800);

    GZipStream zip = new GZipStream(fs, CompressionMode.Decompress, true);
        
    int fileSize = zip.Read(buffer, 0, (int)buffer.Length);

    zip.Write(buffer, 0, (int)buffer.Length);
    zip.Flush();


I get the error : Writing to the compression stream is not supported.
What should i do now ?

This code is in the aspx file, the file can be seen here.http://www.drivehq.com/file/df.aspx/publish/Tamour/wwwhome/do.aspx[^]
note: The name of the file clicked is passed as parameter to do.aspx.
i have read the following forum http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=235208&SiteID=1[^]



Note: Features in SharePoint are actually the services like services in windows.

thanx in advance,
please help me,
im stuck in my project.
AnswerRe: Writing to the compression stream is not supported. Pin
leppie2-Sep-08 1:55
leppie2-Sep-08 1:55 
GeneralRe: Writing to the compression stream is not supported. Pin
tamour2-Sep-08 1:58
tamour2-Sep-08 1:58 
GeneralRe: Writing to the compression stream is not supported. Pin
leppie2-Sep-08 2:02
leppie2-Sep-08 2:02 
GeneralRe: Writing to the compression stream is not supported. Pin
tamour2-Sep-08 2:03
tamour2-Sep-08 2:03 
GeneralRe: Writing to the compression stream is not supported. Pin
leppie2-Sep-08 2:04
leppie2-Sep-08 2:04 
GeneralRe: Writing to the compression stream is not supported. Pin
tamour2-Sep-08 20:09
tamour2-Sep-08 20:09 
AnswerRe: Writing to the compression stream is not supported. Pin
leppie2-Sep-08 2:07
leppie2-Sep-08 2:07 
AnswerRe: Writing to the compression stream is not supported. Pin
Guffa2-Sep-08 3:42
Guffa2-Sep-08 3:42 
AnswerRe: Writing to the compression stream is not supported. Pin
Mbah Dhaim2-Sep-08 10:08
Mbah Dhaim2-Sep-08 10:08 
GeneralRe: Writing to the compression stream is not supported. Pin
tamour2-Sep-08 20:10
tamour2-Sep-08 20:10 
QuestionUsing smo???? Pin
omegazafer2-Sep-08 1:39
omegazafer2-Sep-08 1:39 
AnswerRe: Using smo???? Pin
leppie2-Sep-08 2:01
leppie2-Sep-08 2:01 
GeneralRe: Using smo???? Pin
omegazafer2-Sep-08 11:07
omegazafer2-Sep-08 11:07 
GeneralRe: Using smo???? Pin
leppie2-Sep-08 19:52
leppie2-Sep-08 19:52 
GeneralRe: Using smo???? Pin
omegazafer2-Sep-08 20:09
omegazafer2-Sep-08 20:09 
GeneralRe: Using smo???? Pin
leppie2-Sep-08 20:20
leppie2-Sep-08 20:20 
AnswerRe: Using smo???? Pin
Ashfield2-Sep-08 2:10
Ashfield2-Sep-08 2:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.