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

C#

 
Generalhttp://www.codeproject.com/csharp/BigInteger.asp Pin
James Wanless6-Apr-03 1:24
James Wanless6-Apr-03 1:24 
General= Operator on TabPage Pin
monrobot135-Apr-03 9:28
monrobot135-Apr-03 9:28 
GeneralRe: = Operator on TabPage Pin
James T. Johnson5-Apr-03 14:00
James T. Johnson5-Apr-03 14:00 
GeneralRe: = Operator on TabPage Pin
monrobot135-Apr-03 19:19
monrobot135-Apr-03 19:19 
GeneralAccessing remoting objects from a remoted object Pin
Alex Korchemniy5-Apr-03 8:41
Alex Korchemniy5-Apr-03 8:41 
GeneralStreamReader Pin
Member Salamon5-Apr-03 8:30
Member Salamon5-Apr-03 8:30 
GeneralRe: StreamReader Pin
leppie6-Apr-03 2:10
leppie6-Apr-03 2:10 
GeneralRe: StreamReader Pin
James T. Johnson6-Apr-03 4:50
James T. Johnson6-Apr-03 4:50 
Adding on to what leppie said.

You are getting a null reference exception due to a simple misconception.

while((input = fr.ReadLine()) != null)

input is now equal to the line that was read from the stream, the important point is that line has been removed from the stream. So now the next line of code will eventually fail because:
for(int i =0; i < (fr.ReadLine().Length); i++)

Your loop reads in one line from the stream until it crashes or i is greater than the length of the last line read in (keep in mind you are reading in a line every time through the loop).

What you probably meant to write was:
for(int i =0; i < (input.Length); i++)

So that you process the line of input read in at the start of the while loop.

James

"It is self repeating, of unknown pattern"
Data - Star Trek: The Next Generation

GeneralRe: StreamReader Pin
Member Salamon6-Apr-03 5:26
Member Salamon6-Apr-03 5:26 
GeneralTime trials & registration keys Pin
S O S4-Apr-03 19:25
S O S4-Apr-03 19:25 
GeneralRe: Time trials & registration keys Pin
Alex Korchemniy5-Apr-03 8:49
Alex Korchemniy5-Apr-03 8:49 
GeneralRe: Time trials & registration keys Pin
S O S5-Apr-03 23:06
S O S5-Apr-03 23:06 
QuestionHow to create dynamic Menus in smart device application Pin
newtocsharp4-Apr-03 18:28
newtocsharp4-Apr-03 18:28 
AnswerRe: How to create dynamic Menus in smart device application Pin
Stephane Rodriguez.4-Apr-03 19:15
Stephane Rodriguez.4-Apr-03 19:15 
GeneralRe: How to create dynamic Menus in smart device application Pin
J. Dunlap4-Apr-03 20:03
J. Dunlap4-Apr-03 20:03 
GeneralRe: How to create dynamic Menus in smart device application Pin
newtocsharp4-Apr-03 20:52
newtocsharp4-Apr-03 20:52 
GeneralRe: How to create dynamic Menus in smart device application Pin
Stephane Rodriguez.4-Apr-03 21:25
Stephane Rodriguez.4-Apr-03 21:25 
GeneralIOCP in .NET Pin
BestSnowman4-Apr-03 14:06
BestSnowman4-Apr-03 14:06 
GeneralRe: IOCP in .NET Pin
Alex Korchemniy5-Apr-03 8:52
Alex Korchemniy5-Apr-03 8:52 
GeneralRe: IOCP in .NET Pin
James T. Johnson5-Apr-03 13:45
James T. Johnson5-Apr-03 13:45 
QuestionHow to call the default event handler? Pin
Alvaro Mendez4-Apr-03 11:51
Alvaro Mendez4-Apr-03 11:51 
AnswerRe: How to call the default event handler? Pin
neroknights4-Apr-03 12:00
neroknights4-Apr-03 12:00 
GeneralRe: How to call the default event handler? Pin
Alvaro Mendez4-Apr-03 12:27
Alvaro Mendez4-Apr-03 12:27 
GeneralRe: How to call the default event handler? Pin
neroknights7-Apr-03 5:08
neroknights7-Apr-03 5:08 
AnswerRe: How to call the default event handler? Pin
James T. Johnson5-Apr-03 13:21
James T. Johnson5-Apr-03 13:21 

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.