473,406 Members | 2,352 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,406 software developers and data experts.

Compiling my code not working in C#

I am running make files to build my dlls. I have a web site where my dlls
are in my bin folder and my classes are in a Class folder as are the make
files.

If I run the following from my Classes file
(c:\inetpub\wwwroot\stw\classes), it works fine

vbc /t:library email.vb /r:system.web.dll /r:system.data.dll /r:system.dll
/r:Microsoft.VisualBasic.dll /r:Position.Dll /r:StripHtml.Dll
/r:DBObject.dll

For some reason, I have to put the whole path in from my csc file if my
class is in c#. But I can't find the StripHtml.dll file which is in the
c:\inetpub\wwwroot\stw\bin folder

C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\csc /t:library Position.cs
/r:system.data.dll /r:system.dll /r:nullHandler.dll /r:DBTypes.dll
/r:DBObject.dll /r:StripHtml.dll

It gets the error:

error CS0006: Metadata file 'StripHtml.dll' could not be found

Why does this work for the vbc.exe program but not the csc.exe? Obviously
the StripHtml.dll file is in the bin folder since the vbc.exe program can
find it fine.

Thanks,

Tom
Sep 15 '07 #1
1 1339
Add a reference in the compilation command line. The reason it works for VB
is the VB compiler is a bit less explicit and allows for a sloppier syntax.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

*************************************************
| Think outside the box!
|
*************************************************
"tshad" <tf*@dslextreme.comwrote in message
news:%2****************@TK2MSFTNGP06.phx.gbl...
>I am running make files to build my dlls. I have a web site where my dlls
are in my bin folder and my classes are in a Class folder as are the make
files.

If I run the following from my Classes file
(c:\inetpub\wwwroot\stw\classes), it works fine

vbc /t:library email.vb /r:system.web.dll /r:system.data.dll /r:system.dll
/r:Microsoft.VisualBasic.dll /r:Position.Dll /r:StripHtml.Dll
/r:DBObject.dll

For some reason, I have to put the whole path in from my csc file if my
class is in c#. But I can't find the StripHtml.dll file which is in the
c:\inetpub\wwwroot\stw\bin folder

C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\csc /t:library Position.cs
/r:system.data.dll /r:system.dll /r:nullHandler.dll /r:DBTypes.dll
/r:DBObject.dll /r:StripHtml.dll

It gets the error:

error CS0006: Metadata file 'StripHtml.dll' could not be found

Why does this work for the vbc.exe program but not the csc.exe? Obviously
the StripHtml.dll file is in the bin folder since the vbc.exe program can
find it fine.

Thanks,

Tom

Sep 16 '07 #2

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

Similar topics

0
by: Nikola Milutinovic | last post by:
Hi all. I'm not subscribed to the list, so all replies to me mail directly. I ran into a small problem, for which we have found a workaround. I was compiling PostgreSQL v7.4.1 and it's...
0
by: Matt | last post by:
Just out of the blue all of my code has given a 'Could not instantiate the resource processor.' error on compiling. This apparently means your installation of VS .Net has lost the plot. So I've...
0
by: David W. Fenton | last post by:
Today I was working on a hideous old app that I created a long time ago that does a lot of showing/hiding/resizing of fields on one of the forms. I had used constants to store reference values for...
3
by: Dmitri Shvetsov | last post by:
Hi All, Did somebody have a problem compiling some solution in VS2003? I get the error every time that some files are locked and are using by another process. I repeat compiling again and again...
1
by: Mike Hutton | last post by:
I need some help. I am trying to set up our development environment so as to make life easy for my fellow developers (none of whom have used ASP.NET or VS.NET before). We are developing our...
0
by: Kirt Loki Dankmyer | last post by:
So, I download the latest "stable" tar for perl (5.8.7) and try to compile it on the Solaris 8 (SPARC) box that I administrate. I try all sorts of different switches, but I can't get it to compile....
2
by: Justin Naidl | last post by:
A group of friends and I are doing a RPG (role-playing game) maker for a school project. It occured to us, however, that if you want the user to be able to have almost complete control over the...
0
by: follower | last post by:
This post is mostly Google-bait for anyone else that might want to compile SpiderMonkey ( libjs / libjs.so / libjs.dylib ) for OS X (10.4.5 in my case) and then use it with Python's ctypes. I can't...
10
by: Tomás Ó hÉilidhe | last post by:
I'd post this on a gcc newsgroup but I'd be more productive talking to the wall. Anyway, let's say someone throws some source code at you for a particular program and says, "Just compile it, it...
3
by: entice | last post by:
When I am compiling in visual c++ 2008 express edition I am receiving these two errors main.cpp(224) : error C2664: '_stricmp' : cannot convert parameter 1 from 'WCHAR ' to 'const char *' Types...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.