int is out of scope???

P

PJ6

(VS2003)

? int.Parse("2.0")
error: identifier 'int' out of scope
? "foo".IndexOf("o")
error: expression '"foo".IndexOf' out of scope

For the love of god, why is int and other basic stuff out of scope in my
Command window when I'm debugging?

VB doesn't do this, is this a C# thing?

Paul
 
A

Andy

(VS2003)

? int.Parse("2.0")
error: identifier 'int' out of scope
? "foo".IndexOf("o")
error: expression '"foo".IndexOf' out of scope

For the love of god, why is int and other basic stuff out of scope in my
Command window when I'm debugging?

VB doesn't do this, is this a C# thing?

Paul

Try adding a ; to the end of your statement..
 
C

Christopher Ireland

PJ6 said:
(VS2003)

? int.Parse("2.0")
error: identifier 'int' out of scope
? "foo".IndexOf("o")
error: expression '"foo".IndexOf' out of scope


You'll be pleased to know that both examples work fine in VS2005 :-/

In VS2003 the following works OK:
?Int32.Parse("2")

and even
?"foo".Length

however, I can't get:
?"foo".IndexOf('o')
to work.
 
J

j

? "foo".IndexOf('o')
works...in vs2005
I kept getting "Command "?"foo".IndexOf('o')" is not valid.", until I
added the space.
 
P

PJ6

I'm sorry for this post, Andy, I was angry at having to use C#, and moving
down from 2005 to 2003.

I'll try harder to be more polite in the future, I value the help I receive
in these newsgroups.

Paul
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top