I have a server control as a class within my MySite
assembly (i.e., my site's project not only contains aspx files but also contains server controls which those aspx files reference). I use the following code within an aspx file:
<%@ Register Assembly="MySite" Namespace="MySite.misc" TagPrefix="TAC" %>
...
<TAC:CustomACM ID="myID" runat="server" />
The class's code is as follows:
namespace MySite.misc
{
public class CustomACM : AutoCompleteExtender, INamingContainer
{
//...
}
}
The site works and compiles perfectly, but IntelliSense breaks within myID's children. Changing the namespace within both the class and the register directive to MySiteSC.misc
fixes this, though using MySite.miscSC
does not help. Neither MySiteSC
nor miscSC
is used elsewhere within my solution, and no other CustomACM
class exists within any namespace.
ReSharper underlines "MySite" (i.e., part of the namespace within the register directive) in red with tooltip, "Register Directive is unused and can be safely removed \n Ambiguous Reference." Disabling ReSharper prevents this error from showing up, but does not fix the problem.
Is it possible for me to fix this problem without changing the namespace of the CustomACM control (and without moving the CustomACM control to a different assembly)?