Custom control collapseble panel
-
I want to create a control that has a header (text and and image background) that when clicked, expands/collapses a body content. I want could easily create this with two divs(Div A and B) and a javascipt that sets the style attribute 'display' to 'none' for div B wen clicking div B but I want to hide this implementation. I'd like to be able to use the control somehing like this:
<MyControl ID="cc1" runat="server"> <HeadTemplate class="container_head"> SomeText </HeadTemplate> <ItemTemplate class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </ItemTemplate> MyControl>
...or<MyControl ID="cc1" runat="server" class="container_head" Text="SomeText"> <Div class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </Div> MyControl>
-
I want to create a control that has a header (text and and image background) that when clicked, expands/collapses a body content. I want could easily create this with two divs(Div A and B) and a javascipt that sets the style attribute 'display' to 'none' for div B wen clicking div B but I want to hide this implementation. I'd like to be able to use the control somehing like this:
<MyControl ID="cc1" runat="server"> <HeadTemplate class="container_head"> SomeText </HeadTemplate> <ItemTemplate class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </ItemTemplate> MyControl>
...or<MyControl ID="cc1" runat="server" class="container_head" Text="SomeText"> <Div class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </Div> MyControl>
Perhaps this will help http://www.codeproject.com/aspnet/ExpandingDiv.asp[^]
only two letters away from being an asset
-
I want to create a control that has a header (text and and image background) that when clicked, expands/collapses a body content. I want could easily create this with two divs(Div A and B) and a javascipt that sets the style attribute 'display' to 'none' for div B wen clicking div B but I want to hide this implementation. I'd like to be able to use the control somehing like this:
<MyControl ID="cc1" runat="server"> <HeadTemplate class="container_head"> SomeText </HeadTemplate> <ItemTemplate class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </ItemTemplate> MyControl>
...or<MyControl ID="cc1" runat="server" class="container_head" Text="SomeText"> <Div class="container_body"> <a href="#">List some items</a> <a href="#">Add some item</a> </Div> MyControl>
http://www.codeproject.com/aspnet/XPStyleNavigationBar.asp[^] this too
All C# applications should call Application.Quit(); in the beginning to avoid any .NET problems.- Unclyclopedia My Website | Ask smart questions