Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Can't find a class library dll in design mode

Can't find a class library dll in design mode

Scheduled Pinned Locked Moved C#
helpdesigndebuggingquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tony_Joh
    wrote on last edited by
    #1

    Hello! I have one solution file that consist of three project. One project that build a user control dll. In this user control we have a class called B One project that build a class library dll. In this class library we have a class called C In the user control project I have a project reference to the class library. I build the user control dll and this class library successfully. This user control dll is added to the Toolbox. In the constructor for this class B is a call to instansiate a class C in the class library. When I add this user control to the Toolbox I use directory obj/debug to select the user control dll. So adding the user control works fine. When I drag this user control from the Toolbox into a form that exist in the project that build the exe file object B will be instansiated and another object which is class C will also be instansiated that exist in the class library. Like this. public B() { InitializeComponent(); Last.C last = new Last.C(); last.foo(); } In design mode when we want to design a form that exist in the project that build the exe file we have one dependency the user control is dependent of the class library because an instance of class C will be instansiated as I mentioned before. Now to my problem when I try to drag the user control from the toolbox into a form that exist in the project that build the exe file which search path is used to locate the class library dll because I get this error "An exception occured while trying to create an instance of WindowsControlLibrary.B. The execption was "?"." probably because the class library can't be found. Where should I look and what should I do? I'm rather new to using user control dll and class library. One more additional information is when I drag the use control into a form a get the error message and at the same time two references are added which is the class library dll and the user control dll If I look at the reference path for the class library that was added I discover that my class library exist in this directory. If I look at the reference path for the user control library that was added I discover that my user control library exist in this directory. The two added reference path are the same. //Tony

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups