Step by step guide for developing custom server control with custom collection editor

This guide is step by step instruction to create custom web control. The describe control contains complex property (Collection of classes) that the user can edit using custom type editor. Collection data will be preserving by control as control sub Html tags. This guide also contains most common issues relating to development such a control. The control that we about to develop name is commands and it part of NWAF framework that I'm working on. This control task is to let users to set commands to server control events laid down on web page. Commands has a property holding collection of classes that containing control name, event name and command name set to specify event. The user can add command to control events by using custom editor. Our custom editor show controls on page in hierarchal view. Choosing a control show it server side events and while selecting given event the user can set command name for that event. Controls event commands persist as inner HTML under commands control tags. The HTML output of our control should look like:

<cc1:Commands id="Commands2" style="Z-INDEX: 105; LEFT: 24px; POSITION: absolute; TOP: 107px" runat="server" Height="2px" Width="15px">
    <cc1:InnerCommand EventName="Click" ControlID="Button1" CommandName="a"></cc1:InnerCommand>
    <cc1:InnerCommand EventName="Command" ControlID="Button1" CommandName="b"></cc1:InnerCommand>
    <cc1:InnerCommand EventName="SelectedIndexChanged" ControlID="DropDownList1" CommandName="natty"></cc1:InnerCommand>
    <cc1:InnerCommand EventName="TextChanged" ControlID="TextBox1" CommandName="roni"></cc1:InnerCommand>
</cc1:Commands>

Full article : http://weblogs.asp.net/ngur/articles/144770.aspx

Complete code available for download.

Published Monday, May 31, 2004 5:36 AM by nattYGUR

Comments

# re: Step by step guide for developing custom server control with custom collection editor

Sunday, May 30, 2004 10:59 PM by gas scooter
yes, good

# re: Step by step guide for developing custom server control with custom collection editor

Friday, March 26, 2010 5:44 PM by Felicity

Excuse me. Human beings have an inalienable right to invent themselves. Help me! Help to find sites on the: Turbo tax return. I found only this - <a href="turbo-tax.biz/">turbo tax e file</a>. What learn they get further article? Turbo tax, keyword treea power of non-specific relations is well friendly to now find how spots are including and knowing your philosophy. With best wishes :rolleyes:, Felicity from Indonesia.

Leave a Comment

(required) 
(required) 
(optional)
(required)