Oh no I wasn't advocating you change if that is what you really like. But I don't think the shock value is going to be very high going from JScript to C#. Plus with a language like C# you get the Free IDE's that really kick butt like #Develop. But if that is
what you like more power to you.
I tried your solution and found the answer to my problem: I had made the main function static, you can't call non-static functions from a static scope: static function main() { ....so on.... ask(); ....so on.... } I needed to create a new instance of the Calculator
class and use that to call further functions. This resolved all my problems. Including the STAThread(); bit. I don't know why the compiler said there was an error on that same line, but anyway. However, there is one problem at execution. Nothing appears to
happen! It enters the application, shows one blank line and then exits? I don't suppose you can explain this, can you?
...but mr nberardi, I was just wondering where you got the information to attach the STAThread attribute to my original question? From a web site or something? It's just out of curiosity, but I'd really appreciate it if you told me.
They always add it on in VS.Net. Also Main should always be static so it can be created. And all that should be in Main() is usally Application.Run(new MyForm())
nberardi
Star
11233 Points
2352 Posts
Re: In answer to your question
Feb 11, 2004 12:41 AM|LINK
decpersona
Member
310 Points
62 Posts
Re: In answer to your question
Feb 11, 2004 01:58 AM|LINK
nberardi
Star
11233 Points
2352 Posts
Re: In answer to your question
Feb 11, 2004 11:39 AM|LINK
decpersona
Member
310 Points
62 Posts
Re: In answer to your question
Feb 12, 2004 12:33 AM|LINK
nberardi
Star
11233 Points
2352 Posts
Re: In answer to your question
Feb 12, 2004 03:10 AM|LINK
decpersona
Member
310 Points
62 Posts
Excuse me...
Mar 07, 2004 11:18 PM|LINK
nberardi
Star
11233 Points
2352 Posts
Re: Excuse me...
Mar 08, 2004 12:32 AM|LINK