[Solved] RadToggleSwitch

1 Answer 16 Views
Buttons, RadioButton, CheckBox, etc
Carl
Top achievements
Rank 1
Iron
Iron
Iron
Carl asked on 27 Apr 2026, 08:54 PM

I must be missing something very basic here. I added a RadToggleSwitch to my form and I want it to slide between On and Off like this:

I would have thought that this code would do it:

radToggleSwitch1.OffElement.Text = "Off";
radToggleSwitch1.OnElement.Text = "On";

However, its appearing like this:

I'm sure I'm missing something simple. Any ideas?

Thanks

Carl

1 Answer, 1 is accepted

Sort by
0
Nadya | Tech Support Engineer
Telerik team
answered on 28 Apr 2026, 10:45 AM

Hello, Carl,

Yes, this is the approach to apply text on the OffElement/OnElement, but can you please share with me which is the exact theme that you are using. In some themes, the text may not be drawn due to theme specifics, and I need to check this setting in the specific theme on order to assist you more effectively.

Looking forward to your reply.

Regards,
Nadya | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Carl
Top achievements
Rank 1
Iron
Iron
Iron
commented on 28 Apr 2026, 01:23 PM

Nadya

I'm not specifically assigning a theme to the control, but we are loading a series of themes (see attachment) when the application starts using this code:

public static void LoadThemes()

{
    var files = Directory.GetFiles(Path.GetDirectoryName(Assembly.GetEntryAssembly()?.Location) + "\\CustomThemes\\", "*.tssp");

    foreach (var item in files)
        ThemeResolutionService.LoadPackageFile(item);

    ThemeResolutionService.ApplicationThemeName = Properties.Settings.Default.Theme;
}

The ThemeName property is an empty string and ThemeClassName is Telerik.WinControls.UI.RadToggleSwitch.

When I comment this code however, the RadToggleSwitch appears as I need it to.  I then opened each tssp file and reset the theme for the RadToggleSwitch. Not it looks like this:

How can I get it back to the default shown in the original message?

Thanks

Carl

Nadya | Tech Support Engineer
Telerik team
commented on 30 Apr 2026, 09:24 AM

Hi, Carl,

I am not sure what is your exact setup in the project and also which is your default theme. Here is how you can get which is the applied theme:

// Global app theme (empty = "ControlDefault")
string appTheme = ThemeResolutionService.ApplicationThemeName;

If you do not use the ApplicationThemeName property explicitly in your project and it is never set, it defaults to empty string, meaning that most probably ControlDefault theme is being used as default. In case your project is Telerik WinForms project template the default theme is Fluent.

Keep in mind that our component styles are defined through themes and if you need to customize or modify RadToggleButton it is important to know which theme is currently used so that I can suggest how to customize that specific theme.

You can check the following article about how to customize RadToggleButton: https://www.telerik.com/products/winforms/documentation/controls/buttons/togglebutton/customizing-appearance/accessing-and-customizing-elements 

I hope this information helps. If you have any other questions, do not hesitate to ask.

Tags
Buttons, RadioButton, CheckBox, etc
Asked by
Carl
Top achievements
Rank 1
Iron
Iron
Iron
Answers by
Nadya | Tech Support Engineer
Telerik team
Share this question
or