RadTimePicker Disabled State

5 posts, 1 answers
  1. Mark
    Mark avatar
    41 posts
    Member since:
    Nov 2008

    Posted 04 Feb 2017 Link to this post

    Hello,

    I'm using UI for WinForms R1 2017 and have observed a problem with the drawing of RadTimePicker when in a disabled state (Enabled = false).

    Please see the attached picture. Notice how the RadDateTimePicker control (on the left) has the expected disabled appearance. However, the RadTimePicker control (on the right) does not. Specifically, part of the RadTimePicker editor background is still drawn in a light color when the control is disabled.

    Please let me know if there's a workaround for this, and thanks.

    Regards,

    Mark R.

  2. Dimitar
    Admin
    Dimitar avatar
    2818 posts

    Posted 06 Feb 2017 Link to this post

    Hello Mark,

    This is a known issue which is already logged in our Feedback PortalYou can track its progress, subscribe for status changes and add your comment to it here.

    To work around this, set the back color of the RadTimeMaskedEditBoxElement for the disabled state in Visual Style Builder (see attached image). The following articles shows how you can edit the predefined themes:
    1. Using custom themes
    2. Working With Repository Items
    3. Loading Predefined Themes 

    I hope this will be useful. Let me know if you have additional questions.

    Regards,
    Dimitar
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  3. Mark
    Mark avatar
    41 posts
    Member since:
    Nov 2008

    Posted 06 Feb 2017 in reply to Dimitar Link to this post

    Hello Dimitar,

    Thanks for the quick and helpful reply to my inquiry.

    Is there a way to set the background color for the disabled state programmatically?

    Regards,

    Mark R.

  4. Answer
    Dimitar
    Admin
    Dimitar avatar
    2818 posts

    Posted 07 Feb 2017 Link to this post

    Hi Mark,

    To set this in code you should use the SetThemeValueOverride method:
    radTimePicker1.TimePickerElement.MaskedEditBox.SetThemeValueOverride(RadItem.BackColorProperty, Color.FromArgb(221, 231, 242), "Disabled");

    Do not hesitate to contact us if you have other questions.

    Regards,
    Dimitar
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  5. Mark
    Mark avatar
    41 posts
    Member since:
    Nov 2008

    Posted 07 Feb 2017 in reply to Dimitar Link to this post

    Thanks, Dimitar. That worked perfectly. :-)

    Regards,

    Mark R.

Back to Top