Click here to Skip to main content
16,016,944 members
Home / Discussions / C#
   

C#

 
GeneralRe: Object Serialization with an ArrayList Pin
Hessam Jalali6-Aug-07 9:34
Hessam Jalali6-Aug-07 9:34 
GeneralRe: Object Serialization with an ArrayList Pin
Spyder_Snyper6-Aug-07 9:43
Spyder_Snyper6-Aug-07 9:43 
GeneralRe: Object Serialization with an ArrayList Pin
Hessam Jalali6-Aug-07 9:49
Hessam Jalali6-Aug-07 9:49 
GeneralRe: Object Serialization with an ArrayList [modified] Pin
Spyder_Snyper6-Aug-07 10:36
Spyder_Snyper6-Aug-07 10:36 
GeneralRe: Object Serialization with an ArrayList Pin
cyn86-Aug-07 20:17
cyn86-Aug-07 20:17 
GeneralRe: Object Serialization with an ArrayList Pin
Hessam Jalali6-Aug-07 21:25
Hessam Jalali6-Aug-07 21:25 
GeneralRe: Object Serialization with an ArrayList Pin
Spyder_Snyper7-Aug-07 4:39
Spyder_Snyper7-Aug-07 4:39 
GeneralRe: Object Serialization with an ArrayList Pin
Hessam Jalali7-Aug-07 6:43
Hessam Jalali7-Aug-07 6:43 
if you don't need your Stream after serialization process you can simply use FileStream instead of MemoryStream and directly save it to the disk.

but if you need your stream so you can save it using StreamWriter Class

<code>

        void SaveToDisk(string path, Stream stream)
        {
            stream.Seek(0, SeekOrigin.Begin); //put the pointer at first
            using (StreamWriter sw = new StreamWriter(path))
            using (StreamReader sr = new StreamReader(stream))
            {
                sw.Write(sr.ReadToEnd());
                sw.Flush();
            }
        }

</code>


if you had problem with StreamWriter and Reader you can use BinaryWriter and Reader (a little bit harder to use but I don't think you need them)

good Luck my Friend Smile | :)
QuestionCannot generate SSPI context error Pin
xbiplav6-Aug-07 5:17
xbiplav6-Aug-07 5:17 
AnswerRe: Cannot generate SSPI context error Pin
snorkie6-Aug-07 11:49
professionalsnorkie6-Aug-07 11:49 
AnswerRe: Cannot generate SSPI context error Pin
mav.northwind7-Aug-07 1:18
mav.northwind7-Aug-07 1:18 
QuestionFile Encoding Pin
Sean_B6-Aug-07 4:22
Sean_B6-Aug-07 4:22 
AnswerRe: File Encoding Pin
Luc Pattyn6-Aug-07 4:37
sitebuilderLuc Pattyn6-Aug-07 4:37 
GeneralRe: File Encoding Pin
Sean_B6-Aug-07 5:26
Sean_B6-Aug-07 5:26 
QuestionPNG compression? Pin
Mad_Mike6-Aug-07 3:52
Mad_Mike6-Aug-07 3:52 
AnswerRe: PNG compression? [modified] Pin
PhilDanger6-Aug-07 4:11
PhilDanger6-Aug-07 4:11 
GeneralRe: PNG compression? Pin
Mad_Mike6-Aug-07 4:14
Mad_Mike6-Aug-07 4:14 
GeneralRe: PNG compression? Pin
PhilDanger6-Aug-07 4:29
PhilDanger6-Aug-07 4:29 
GeneralRe: PNG compression? Pin
Mad_Mike6-Aug-07 5:04
Mad_Mike6-Aug-07 5:04 
Questionexcel Pin
TAREQ F ABUZUHRI6-Aug-07 3:10
TAREQ F ABUZUHRI6-Aug-07 3:10 
AnswerRe: excel Pin
Nisar Inamdar6-Aug-07 3:13
Nisar Inamdar6-Aug-07 3:13 
GeneralRe: excel Pin
TAREQ F ABUZUHRI6-Aug-07 4:03
TAREQ F ABUZUHRI6-Aug-07 4:03 
AnswerRe: excel Pin
Vasudevan Deepak Kumar6-Aug-07 3:23
Vasudevan Deepak Kumar6-Aug-07 3:23 
AnswerRe: excel Pin
Giorgi Dalakishvili6-Aug-07 3:25
mentorGiorgi Dalakishvili6-Aug-07 3:25 
AnswerRe: excel Pin
Bhavesh Bagadiya6-Aug-07 4:26
Bhavesh Bagadiya6-Aug-07 4:26 

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.