Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Building Controls > Skinnable User Controls?

Reply
Thread Tools

Skinnable User Controls?

 
 
Andrew Clancy
Guest
Posts: n/a
 
      01-19-2006
Hi,

I'm hoping to create a skinnable user control in ASP.Net, using the skin
file to keep things streamlined & all in one place/technique. 1st attemp
went something like this
Test.ascx:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Test.ascx.cs"
Inherits="Test" EnableTheming="true" %><asp:TextBox ID="TextBox1"
runat="server"></asp:TextBox><asp:Button ID="Button1" runat="server"
Text="Button" />
Default.skin:
<%@ Register Src="~/Test.ascx" TagName="Test" TagPrefix="uc1" %>
<uc1:Test runat="server" />
Error Message: The control type 'ASP.test_ascx' cannot be themed

Anyone got any ideas if this is possible, and/or any examples references on
how?
Ideally I want to be able to do something like this so I can completely
customise the html/layout.

<%@ Register Src="~/Test.ascx" TagName="Test" TagPrefix="uc1" %>
<uc1:Test runat="server" ><template><asp:TextBox ID="TextBox1"
runat="server"></asp:TextBox><asp:Button ID="Button1" runat="server"
Text="Button" /><template></uc1:Test>

Cheers,
Andy C



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Restrict user if user directly types url of any page Jaydeep ASP .Net 3 06-30-2006 04:40 AM
Skinnable User Controls? Andrew Clancy ASP .Net 0 01-19-2006 12:20 AM
Skinnable User Controls? Andrew Clancy ASP .Net Web Controls 0 01-19-2006 12:20 AM
Skinnable/Stylable windows in wxPython? Daniel Bickett Python 5 12-22-2004 10:54 PM
Manipulating a User Control from another User Control Tom Rowton ASP .Net 2 08-01-2003 08:18 PM



Advertisments