Click here to Skip to main content
15,922,630 members
Home / Discussions / C#
   

C#

 
AnswerRe: cheked list box control Pin
leppie3-Jul-08 2:07
leppie3-Jul-08 2:07 
GeneralRe: cheked list box control Pin
Hum Dum3-Jul-08 2:13
Hum Dum3-Jul-08 2:13 
GeneralRe: cheked list box control Pin
leppie3-Jul-08 2:20
leppie3-Jul-08 2:20 
GeneralRe: cheked list box control Pin
Hum Dum3-Jul-08 2:38
Hum Dum3-Jul-08 2:38 
GeneralRe: cheked list box control Pin
leppie3-Jul-08 3:57
leppie3-Jul-08 3:57 
QuestionHow to protect my c# code from decompiling Pin
Member 17396853-Jul-08 1:42
Member 17396853-Jul-08 1:42 
AnswerRe: How to protect my c# code from decompiling Pin
N a v a n e e t h3-Jul-08 1:48
N a v a n e e t h3-Jul-08 1:48 
GeneralRe: How to protect my c# code from decompiling Pin
Member 17396853-Jul-08 1:56
Member 17396853-Jul-08 1:56 
GeneralRe: How to protect my c# code from decompiling Pin
leppie3-Jul-08 2:08
leppie3-Jul-08 2:08 
GeneralRe: How to protect my c# code from decompiling Pin
Member 17396853-Jul-08 3:06
Member 17396853-Jul-08 3:06 
GeneralRe: How to protect my c# code from decompiling Pin
Gareth H3-Jul-08 3:35
Gareth H3-Jul-08 3:35 
GeneralRe: How to protect my c# code from decompiling Pin
ajtunbridge3-Jul-08 4:03
ajtunbridge3-Jul-08 4:03 
GeneralRe: How to protect my c# code from decompiling Pin
Member 17396856-Jul-08 23:49
Member 17396856-Jul-08 23:49 
GeneralRe: How to protect my c# code from decompiling Pin
Gareth H7-Jul-08 1:43
Gareth H7-Jul-08 1:43 
GeneralRe: How to protect my c# code from decompiling Pin
Thomas Stockwell3-Jul-08 10:14
professionalThomas Stockwell3-Jul-08 10:14 
AnswerRe: How to protect my c# code from decompiling Pin
Thomas Stockwell3-Jul-08 10:12
professionalThomas Stockwell3-Jul-08 10:12 
Questiongeneric collection Pin
arkiboys3-Jul-08 1:36
arkiboys3-Jul-08 1:36 
AnswerRe: generic collection Pin
N a v a n e e t h3-Jul-08 1:47
N a v a n e e t h3-Jul-08 1:47 
QuestionUsing a C++ LIB in C# Pin
indogerman3-Jul-08 1:21
indogerman3-Jul-08 1:21 
AnswerRe: Using a C++ LIB in C# Pin
leppie3-Jul-08 2:11
leppie3-Jul-08 2:11 
QuestionNeed help coding a MathML to C# converter Pin
Dmitri Nеstеruk3-Jul-08 0:13
Dmitri Nеstеruk3-Jul-08 0:13 
AnswerRe: Need help coding a MathML to C# converter Pin
leppie3-Jul-08 2:16
leppie3-Jul-08 2:16 
GeneralRe: Need help coding a MathML to C# converter Pin
Dmitri Nеstеruk3-Jul-08 5:16
Dmitri Nеstеruk3-Jul-08 5:16 
AnswerRe: Need help coding a MathML to C# converter Pin
leppie3-Jul-08 2:17
leppie3-Jul-08 2:17 
Questionbyte[] to ArrayList Pin
Rick van Woudenberg3-Jul-08 0:10
Rick van Woudenberg3-Jul-08 0:10 
Dear all,

I'm stuck once again and calling on you for aid. I want to convert a byte array to an arraylist. I managed to write some code that will put my byte[] data in a file :

Byte[] result = (Byte[])foundRows[0]["bin_file"];
using (BinaryWriter binWriter = new BinaryWriter(File.Open("@C:\test.txt", FileMode.Create)))
{
    binWriter.Write(result);
}


This works fine but I would like to write it to an ArrayList so I can process it from there. Reading it back from the file into an ArrayList seems unlogical for me and unneccesary too.


ArrayList list = new ArrayList();
StreamReader se = new StreamReader("@C:\test.txt");
string line = se.ReadLine();
while (line != null)
{
    list.Add(line);
    //Read the next line
    line = se.ReadLine();
}

se.Close();



Can somebody point me in the right direction on how to tackle this problem ? With other words, how can I put my byte[] data directly into an ArrayList.

Kind regards,

Rick

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.