Tagprefix to my server controls

W

wapsiii

I'd like to set the tagprefix of my server controls automatically when
they are dragged to the webform.

My code reads

<Assembly: TagPrefix("CtrlLib", "abc")>
Namespace CtrlLib

<DefaultProperty("Text"), ToolboxData("<{0}:TextBoxPlus
runat=server></{0}:TextBoxPlus>")> _
Public Class TextBoxPlus : Inherits
System.Web.UI.WebControls.TextBox

However, after adding the control to the toolbox and dragging the
control to the webform the tagprefix still reads <cc1:TextBoxPlus ...

What am I missing?

/M
 
C

Craig Deelsnyder

I'd like to set the tagprefix of my server controls automatically when
they are dragged to the webform.
However, after adding the control to the toolbox and dragging the
control to the webform the tagprefix still reads <cc1:TextBoxPlus ...

What am I missing?

/M

for 1.x?
http://weblogs.asp.net/kwarren/archive/2004/01/07/48457.aspx

note the issue mentioned in the comments, that all controls with the same
prefix have to be in same assembly...not a huge deal, most times you are
using 1 assembly. dunno if 2.x does it differently...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top