We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Platform : ASP.NET
|
Category : Custom Controls

How do I insert custom @ Register tags into the aspx file from my custom control

In the custom control's custom designer's Initialize override, do something like this:

Then when the user drags and drops the item from the toolbox, besides the default @ register entry it makes, it will also make an entry like this: <%@ Register TagPrefix="cc1" Namespace="SomeNamespace" Assembly="DependantAssembly, Version=2.0.0.1, Culture=neutral, PublicKeyToken=3d6dfsd1fdsd44c89" %>

The assembly will not be strong named in the above tag if it's not in the GAC.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.