473,385 Members | 1,357 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

can't get csc.exe to run from any dir I happen to be in

MS
Hi,

This should be trivial but I can't get csc.exe to run from any dir that I
happen to be in.

I had this setup before but just installed 'dotnet 2.0 beta 2 Framework
SDK'. When I click on the 'SDK Command Prompt' (Start Menu, Programs, .Net
Menu) I get a command window which starts in the dir:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

"csc whatever.cs" works fine there.

so I added that path to my environment variable 'path', but csc still
didn't work from any dir EG. "C:\JMS\CSHARP\Soduku". Strange! Closer
inspection revealed csc.exe is not in:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

but is actually in:

"C:\WINNT\Microsoft.NET\Framework\v2.0.50215"

so I added that dir to my 'path' too. It still doesn't work.

How do I get this working so I don't have to worry about the path to
csc.exe when I'm compiling?

Thanks,

MS
Nov 17 '05 #1
2 1590
The VS command promps runs the SDKVARS.BAT file that is situated in the SDK
directory. On my machine the path is:

C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1\Bin\sdkvars.bat

It may be different on yours.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"MS" <matthews@mailsnare.---nojunktakeout---.net> wrote in message
news:uQ**************@TK2MSFTNGP15.phx.gbl...
Hi,

This should be trivial but I can't get csc.exe to run from any dir that I
happen to be in.

I had this setup before but just installed 'dotnet 2.0 beta 2 Framework
SDK'. When I click on the 'SDK Command Prompt' (Start Menu, Programs, .Net
Menu) I get a command window which starts in the dir:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

"csc whatever.cs" works fine there.

so I added that path to my environment variable 'path', but csc still
didn't work from any dir EG. "C:\JMS\CSHARP\Soduku". Strange! Closer
inspection revealed csc.exe is not in:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

but is actually in:

"C:\WINNT\Microsoft.NET\Framework\v2.0.50215"

so I added that dir to my 'path' too. It still doesn't work.

How do I get this working so I don't have to worry about the path to
csc.exe when I'm compiling?

Thanks,

MS

Nov 17 '05 #2
On Tue, 09 Aug 2005 21:54:36 +0100, MS
<matthews@mailsnare.---nojunktakeout---.net> wrote:
Hi,

This should be trivial but I can't get csc.exe to run from any dir that I
happen to be in.

I had this setup before but just installed 'dotnet 2.0 beta 2 Framework
SDK'. When I click on the 'SDK Command Prompt' (Start Menu, Programs, .Net
Menu) I get a command window which starts in the dir:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

"csc whatever.cs" works fine there.

so I added that path to my environment variable 'path', but csc still
didn't work from any dir EG. "C:\JMS\CSHARP\Soduku". Strange! Closer
inspection revealed csc.exe is not in:

"C:\Program Files\Microsoft.NET\SDK\v2.0"

but is actually in:

"C:\WINNT\Microsoft.NET\Framework\v2.0.50215"

so I added that dir to my 'path' too. It still doesn't work.

How do I get this working so I don't have to worry about the path to
csc.exe when I'm compiling?

Thanks,

MS


Are you trying to do your compiling from the SDK command window?

If so you should be able to change directories to the one holding your
code (cd) and run the 'csc' command from there.
Ken Wilson
Seeking viable employment in Victoria, BC
Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: lawrence | last post by:
How dangerous or stupid is it for an object to have a reference to the object which contains it? If I have a class called $controllerForAll which has an arrray of all the objects that exist, what...
3
by: Ian Richardson | last post by:
I have some example code below where, when I click on the background of the table I want one thing to happen (wilma), and when I click on the text box I want one different thing to happen (fred). ...
22
by: The Road To Utopia | last post by:
Here's one for the trolls...a common jibe from them is setting up audio/video hardware under linux. Ok, true story: at work today, someone asked me if I could tell him why his XP Home would play...
3
by: Professor Frink | last post by:
First off, I apologize if this gets long. I'm simply trying to give you all enough information to help me out. I'm writing (almost finished, actually), my first VB.Net application. It's a forms...
0
by: phoebe | last post by:
hi all, first,thank you for coming in! I have some problem on a Windows application in .Net Framework,just as below,also you can get the whole project in the attachment(in c#). private void...
3
by: eieiohh | last post by:
MySQL 3.23.49 PHP 4.3.8 Apache 2.0.51 Hi All! Newbie.. I had a CRM Open Source application installed and running. Windows Xp crashed. I was able to copy the contents of the entire hard...
46
by: Ian Boyd | last post by:
IIS5, on a Windows 2000 Server machine. Debeg.WriteLine "Hello, world!" How can i view it?
16
by: Mr. Ken | last post by:
Left shift by negative numbers, will I get 1/2? Thanks.
4
by: etuncer | last post by:
Hello All, I have Access 2003, and am trying to build a database for my small company. I want to be able to create a word document based on the data entered through a form. the real question is...
4
by: Joseph Geretz | last post by:
We use a Soap Header to pass a token class (m_Token) back and forth with authenticated session information. Given the following implementation for our Logout method, I vastly prefer to simply code...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.