Hi.
I installed Visual Studio 2008, and it works great. But some tutorials I'm going through instruct me to use the command line (cmd) to run my application via "csc helloworld.cs" I realize I can just do what I want to via Visual Studio 2008, but I'd also like to get familiar with the command line.
However, try and run something via csc, it doesn't recognize that, and sure enough, in the Path variable, there is nothing pointing to any kind of csc.exe or anything. A file search for csc.exe also yields no results.
Maybe I'm mistaken, but I thought by installing Visual Studio 2008, I was also installing the C# language (because I can compile and run C# programs with it).
Can someone provide both a solution and a kind of brief explanation of what exactly I installed with Visual Studio 2008 and how that differs from just installing the C# language?
Thanks.
Mega stupid question about setting the windows path variable to run .cs files
Started by captainsupermarket, Aug 18 2010 08:13 PM
3 replies to this topic
#1
Posted 18 August 2010 - 08:13 PM
|
|
|
#2
Posted 18 August 2010 - 10:08 PM
The .NET SDK should include the c-sharp compiler (csc.exe) within Microsoft.NET\Framework\<version>\ usually, you have it installed?
Be sure to read the updated FAQ! || Health is achieved through the same 10,000 steps.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
#3
Posted 18 August 2010 - 10:36 PM
Thank you for your reply, much appreciated.
Basically, I had the Microsoft Visual Studio 2008 CD, and it installed a ton, the installation took forever. I recall that it installed the .NET Framework, and then I remember Windows Update updated it. On top of that, I can make C# programs in Visual Studio and use them from there, no problem.
So if I go to Program Files and look, there is indeed a Microsoft.NET folder. Inside it are four folders and no other files:
ADOMD.NET
Primary Interop Assemblies
RedistList
SDK
I checked them all out, and none of them eventually lead to a csc.exe. I did the system wide file search for csc.exe as well, only to get 0 results.
The thing is, when I make a .cs file, the system recognizes the .cs file type as a "Visual C# Source File," as opposed to a generic C# file. It's as if Visual Studio has dominated the .cs file type as it's own file type, as opposed to just installing the regular C# language itself that could be used by other SDK's.
Basically, I had the Microsoft Visual Studio 2008 CD, and it installed a ton, the installation took forever. I recall that it installed the .NET Framework, and then I remember Windows Update updated it. On top of that, I can make C# programs in Visual Studio and use them from there, no problem.
So if I go to Program Files and look, there is indeed a Microsoft.NET folder. Inside it are four folders and no other files:
ADOMD.NET
Primary Interop Assemblies
RedistList
SDK
I checked them all out, and none of them eventually lead to a csc.exe. I did the system wide file search for csc.exe as well, only to get 0 results.
The thing is, when I make a .cs file, the system recognizes the .cs file type as a "Visual C# Source File," as opposed to a generic C# file. It's as if Visual Studio has dominated the .cs file type as it's own file type, as opposed to just installing the regular C# language itself that could be used by other SDK's.
#4
Posted 18 August 2010 - 11:40 PM
I'm sure your CD did not include the 2008 SDK as it's roughly 100MBs; you'll need to download the .NET SDK manually, try this:
http://www.microsoft...&displaylang=en
MSDN says the CS compiler is within, so why not give it a try?
http://www.microsoft...&displaylang=en
MSDN says the CS compiler is within, so why not give it a try?
Be sure to read the updated FAQ! || Health is achieved through the same 10,000 steps.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account

Back to top









