Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 373679
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T14:19:53+00:00 2026-05-12T14:19:53+00:00

I am creating a custom composite control based off of an asp:Label control. I’d

  • 0

I am creating a custom composite control based off of an asp:Label control. I’d like to be able to have the label’s default properties be skinable as well as additional properties that I add to my control.

But when I add a skin definition to the Default.skin file in my themes directory, and add the control to my page with the SkinId specified, I cannot figure out how to get the control to render with the Skinned properties.

Additional points:

  • My custom control is defined in a separate library/dll.
  • I added one test property, and added the [Themeable(false)] attribute. Then I set that property in the .skin file. I didn’t get any errors when I tried to view the page, so it appears to me that the .skin file is not getting applied or that the control def in the skin file doesn’t get matched up with the control def in the aspx page.

From the skin file:

<ctrl:ExtendedLabel SkinId="test" runat="server"
 Expandable="true" Lookup="true" Required="true"
 RequiredCssClass="required" Text="Hello" />

From the aspx page:

<ctrl:ExtendedLabel SkinID="test" runat="server"/>

From web.config:

<pages>
  <controls>
     <add tagPrefix="ctrl" namespace="MyCompany.WebControls"
          assembly="MyCompany.Web" />
  </controls>
</pages>

I added a test property to the control, marked it as [Themeable(false)] in order to test if I’d get the runtime error when setting that property in the skin file. No error.

Notice that the pages tag doesn’t have a styleSheetTheme attribute. I do however, have a Base page class that overrides StyleSheetTheme property, which seems to work for everything else.

If I add the styleSheetTheme attribute to the pages tag in web.config, the skin stuff works, including getting the error if I try to set the non-Themeable property.

What’s the difference? How can I get it to work with the Base page class property code?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T14:19:54+00:00Added an answer on May 12, 2026 at 2:19 pm

    What are you getting when you try this? I just created a simple test project and was able to skin a custom property on a web custom control. My steps were:

    • Create the custom control.
    • Add [Themeable(true)] attribute to the class definition in the code-behind file.
    • Add a Label control to my custom control.
    • Add a property named “LabelText” to my custom control, which gets/sets the label controls Text value.
    • In web.config, add ‘theme=”TestTheme”‘ to the system.web/pages section.
    • In web.config, add ‘<add tagPrefix=”mine” tagName=”Test” src=”~/UI/Test.ascx” />’ to the system.web/pages/controls section.
    • In my Default.skin file, added ‘<mine:Test runat=”server” LabelText=”Test Text” />
    • In Default.aspx, added ‘<mine:Test id=”test1″ runat=”server” />’

    Load the page up and see the text “Test Text”, which was only present in the Skin file.

    Hopefully one of my steps above will be something you forgot, but if not, please update your question with details on what you are trying and what you are seeing.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 243k
  • Answers 243k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer 2 improvements: no copy of the array (just using the… May 13, 2026 at 7:55 am
  • Editorial Team
    Editorial Team added an answer You may take a look at this article. You could… May 13, 2026 at 7:55 am
  • Editorial Team
    Editorial Team added an answer Temporarily encode <a href ...>...</a> into something else, remove all… May 13, 2026 at 7:55 am

Related Questions

I am creating a custom composite control based off of an asp:Label control. I'd
I am developing an ASP.Net web app that needs to run in a Kiosk/Touch
I am creating a custom WPF control that let's say for simplicity sake has
I am creating a custom UITableViewCell to include an UIImageView and some related text.
I am creating a custom control using C# GDI+. Quick explanation...the control will be

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.