Reputation: 21271
I have two applications
WORKING STRUCTURE
The code of child application is compiled from the parent application.
I have added a DLL
named MyDLL.dll
in the parent application(There is a feature in parent application to upload DLL and compile code of child application from there). The child application also consumes that DLL
.
Now I need to create a DLL
of child application. Since MyDLL.dll
is in parent application I cannot build the project of child application individually(since child application also consumes that MyDLL.dll
).
When I build the child application, its showing the error : Could not Find namespace MyDll. Are you missing an assembly reference?
CODE
1. Parent Application
using MyDll;
namesapace MyNamespace
{
class ParentApplication
{
}
}
2. Child Application
using MyDll;
namesapace ChildNamespace
{
class ChildApplication
{
}
}
How do I generate a DLL
of child application without building project of child application?
Upvotes: 0
Views: 134
Reputation: 46
You need to build the child application because until the code is compiled into a dll then well, its just code on a screen. Since, C# is compiled into Microsoft Intermediate Language MISL which is then compiled against the common language run time (CLR) and then that is made to native code like machine code. Where you can read more about here. So in short, you have to build the child application, no other way around it.
It also seems like you aren't using the right location for the MyDll.dll
, where exactly is it located?
Upvotes: 3