Click here to Skip to main content
15,892,005 members
Home / Discussions / C#
   

C#

 
GeneralRe: Writing Unit Tests Pin
Daniel Turini31-Aug-04 6:47
Daniel Turini31-Aug-04 6:47 
QuestionHow to intercept alerts from embedded programs? Pin
Member 129675731-Aug-04 5:57
Member 129675731-Aug-04 5:57 
AnswerRe: How to intercept alerts from embedded programs? Pin
Judah Gabriel Himango31-Aug-04 7:33
sponsorJudah Gabriel Himango31-Aug-04 7:33 
GeneralRe: What is missing? C# Pin
adnanh7531-Aug-04 5:04
adnanh7531-Aug-04 5:04 
GeneralDrag and Drop between two treeviews-drawing a line Pin
Cagatay Bilgin31-Aug-04 4:47
Cagatay Bilgin31-Aug-04 4:47 
GeneralRe: Drag and Drop between two treeviews-drawing a line Pin
LongRange.Shooter1-Sep-04 8:13
LongRange.Shooter1-Sep-04 8:13 
QuestionWhat is missing? C# Pin
adnanh7531-Aug-04 4:32
adnanh7531-Aug-04 4:32 
AnswerRe: What is missing? C# Pin
Steve Maier31-Aug-04 4:59
professionalSteve Maier31-Aug-04 4:59 
I would make the code look like this:

private void panel13_Paint(object sender, System.Windows.Forms.PaintEventArgs e)
{
    ArrayList nodes = new ArrayList();
    StreamReader sr = File.OpenText("C:\\NeckingRa\\Temp\\cut.dat");
    String line;
    while ((line=sr.ReadLine())!=null)
    {
        string[] values = line.Split(' ');
        nodes.AddRange(values);
    }
    sr.Close();
}
The file variable is not needed and inside of the while look you were reading to the end of the file. Also you had never added the data in values to the nodes variable. I also like using @"c:\NeckingRa\Temp\cut.dat" in C# instead of the normal \\ that we all had to use in C++.

Steve Maier, MCSD MCAD
GeneralWait Thread close Pin
jzb31-Aug-04 4:23
jzb31-Aug-04 4:23 
GeneralRe: Wait Thread close Pin
Corinna John31-Aug-04 5:11
Corinna John31-Aug-04 5:11 
GeneralAcquire object name at runtime Pin
TehMedic31-Aug-04 1:36
TehMedic31-Aug-04 1:36 
GeneralRe: Acquire object name at runtime Pin
Nick Parker31-Aug-04 3:29
protectorNick Parker31-Aug-04 3:29 
GeneralRe: Acquire object name at runtime Pin
TehMedic1-Sep-04 0:13
TehMedic1-Sep-04 0:13 
QuestionSOS:How to make properties displayed in the property grid in the special order as I expected? Pin
dotnet_paradise31-Aug-04 1:10
dotnet_paradise31-Aug-04 1:10 
AnswerRe: SOS:How to make properties displayed in the property grid in the special order as I expected? Pin
leppie31-Aug-04 3:26
leppie31-Aug-04 3:26 
GeneralRe: SOS:How to make properties displayed in the property grid in the special order as I expected? Pin
dotnet_paradise31-Aug-04 4:42
dotnet_paradise31-Aug-04 4:42 
GeneralSockets and threads! How to scale well :P Pin
Salil Khedkar31-Aug-04 0:44
Salil Khedkar31-Aug-04 0:44 
GeneralRe: Sockets and threads! How to scale well :P Pin
Joel Lucsy31-Aug-04 15:54
Joel Lucsy31-Aug-04 15:54 
GeneralRe: Sockets and threads! How to scale well :P Pin
Heath Stewart1-Sep-04 9:43
protectorHeath Stewart1-Sep-04 9:43 
GeneralRe: Sockets and threads! How to scale well :P Pin
Pradeep Shamarao3-Sep-04 1:26
Pradeep Shamarao3-Sep-04 1:26 
GeneralRe: Sockets and threads! How to scale well :P Pin
Heath Stewart3-Sep-04 6:23
protectorHeath Stewart3-Sep-04 6:23 
GeneralRe: Sockets and threads! How to scale well :P Pin
Pradeep Shamarao5-Sep-04 21:00
Pradeep Shamarao5-Sep-04 21:00 
GeneralRe: Sockets and threads! How to scale well :P Pin
Heath Stewart6-Sep-04 8:58
protectorHeath Stewart6-Sep-04 8:58 
GeneralUnnecessary space removal Pin
Nirmalan31-Aug-04 0:31
Nirmalan31-Aug-04 0:31 
GeneralRe: Unnecessary space removal Pin
Nick Parker31-Aug-04 3:34
protectorNick Parker31-Aug-04 3:34 

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.