> > c#, .Net 2.0, VS2008
>
[quoted text clipped - 24 lines]
>
> Pete
The situation is I have the source for both of the components in the
same project. Simplifying it, I have a control derived from the
TabPage, and another control derived from the CheckBox, which I wish
to programmatically place on the TabPage.
Both controls are in the same project, and using the same namespace.
I can use either control in any part of the project (eg put the
derived checkbox on the mainform), just not use it in the custom
tabpage control.
Note: I am not trying to solve the specifics of how to add the
checkbox derived control, but generically, as there are a few other
controls I wish to use on my derived TabPage.
Even when I tried to use a DLL of the custom controls, and referenced
the assembly in the project, I still got the same error.
Peter Duniho - 30 Nov 2007 18:33 GMT
> [...]
> Even when I tried to use a DLL of the custom controls, and referenced
> the assembly in the project, I still got the same error.
As I wrote, this is usually not a difficult thing to fix. The
compilation error provides detailed information that should lead you to
a solution.
But you haven't provided enough information here for anyone else to
answer the question. The exact wording of the compilation error and a
concise-but-complete sample of code demonstrating the problem would be
required.
You claim that both controls are in the same project and in the same
namespace. If so, then you've either got a typo or a conflicting name
or you've failed to completely qualify a nested type or you're wrong
about them being in the same project and namespace. As you can see,
there are a variety of things that could cause the error you're
describing and so there's no way for anyone else to know which of those
problems is actually the issue as long as you continue to withhold the
important details.
Pete