Terentius Neo <te***********@here.fi> wrote in
news:YK**************@read3.inet.fi:
I have two classes, A and B, both in the same namespace. If I
compile files to a DLL, the A class does not compile. The error
message is
"[C# Error] BaseObject.cs(69): The type or namespace name
'Logger' could not be found (are you missing a using directive
or an assembly reference?)"
Note: there *is* using clause.
If I compile both as part of the same EXE there is no problem.
The code is the same!
Terentius,
A using clause is not the same as an assembly reference. If you are
compiling from the command line, you need to add an assembly
reference for the assembly that contains the Logger class:
csc /t:library /r:Logger.dll BaseObject.cs
If you are using Visual Studio, expand the References node for the
project in the Solution Explorer and add a reference to Logger's
assembly.
--
Hope this helps.
Chris.
-------------
C.R. Timmons Consulting, Inc.
http://www.crtimmonsinc.com/