Custom Web Control - attribute/property prefix

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I want to prefix my attributes in a custom control. So like this:
<x:Mycontrol x:id="22" x:name="SomeName" runat="server"/>

Now I get a "The server tag is not well formed.". Do you know any solution?
 
I know there are better sololutions, but the hole application need the
xmlns:x="http://website" namespace(for XHTML).
So it's nice to have this also on the custum control tag(so a user thinks
it's a custom XHTML tag with only a ranat="server" attribute). Do you have a
solution?
 
I'll explain this by this code:
<%@ Register TagPrefix="x" Namespace="myspace" Assembly="mycontrol" %>
<html xmlns:x="http://myweb">
<x:table x:id="_mytable">
<x:tr>
<x:td><x:TextBox x:id="25" x:Text=""
runat="server"/><x:/td>
</x:tr>
<x:table>
</html>

You see... i've got client side tags with tag and attribute prefixes. Now I
also want to put these on my custom control, so a XHTML programmer doesn't
see it's a server side control(exept the runat attribute)
 
Back
Top