New C# User - Problems referencing System namespace

Joined
Jun 13, 2005
Messages
4
Reaction score
0
Here is the easiest question you’ll get all day from a complete newbie. I installed Visual Studio on my laptop last night and have been trying to write my very first C# programs this morning. I’m running into a few issues that I’m sure someone on this forum will be able to help me understand quickly.

I started out with a traditional “Hello World” program, again, my first C# programs. I was surprised to see how the System namespace was referenced in the code that was generated by the IDE. In addition, it looks like the IDE generates code that explicitly referenced items from the System namespace using a notation that looks something like “System::item”. I haven’t seen this in any of the C# books that I’ve referenced. Each of these books suggests that you simply need to issue a “using System;” and I should be able to reference any item from the System namespace.

I then tried to create a variable of value type “decimal”. It looks to me like “decimal” should be defined in the System namespace. The first thing I noticed was that the IDE did not color the keyword “decimal” in blue like it did for the other value types I had used (i.e. int, string, etc.). Sure enough, when I tried to compile the program, the complier didn’t recognize the keyword “decimal”.

I’m sure that these issues are all related somehow. Can someone direct me to some additional information that would help be figure out what I’m doing wrong here so I can get through my first few C# programs?
 
Back
Top