How to remove border colour from NumbricUpDown

7 posts, 1 answers
  1. Jing
    Jing avatar
    6 posts
    Member since:
    Jan 2011

    Posted 27 Apr 2011 Link to this post

    When NumbricUpDown is on focus or button be clicked, the border colour will change to organe by default. Is there anyway I can turn the colour changing off?

    Thanks

    Jing
  2. Dani
    Admin
    Dani avatar
    848 posts

    Posted 28 Apr 2011 Link to this post

    Hi Jing,

    The RadNumericUpDown control contains in its template a ButtonChrome control , which is responsible for all states. If you edit the RadNumericUpDown control in Blend and find the ButtonChrome control, you can set its RenderMouseOver or RenderFocused properties to False - this will prevent the states from being rendered.

    Regards,
    Dani
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
  4. Jing
    Jing avatar
    6 posts
    Member since:
    Jan 2011

    Posted 28 Apr 2011 Link to this post

    Hi,Dani

    Thanks for the reply. I set RenderMouseOver and RenderFocused both to False, but it still shows the orange colour when I mouse over or got keboard focus.

    Cheers
  5. Dani
    Admin
    Dani avatar
    848 posts

    Posted 29 Apr 2011 Link to this post

    Hi Jing,

    I prepared a sample demonstrating the RadNumericUpDown control with no MouseOver and Focused states for you. I am sorry I did not give you more detailed information. Check the commented out parts of the RadNumericUpDown template, as well as the ButtonChrome removed states.

    I hope this helps.

    All the best,
    Dani
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  6. Jing
    Jing avatar
    6 posts
    Member since:
    Jan 2011

    Posted 01 May 2011 Link to this post

    Hi Dani

    Thanks for your help. It works mostly what I want it to be, Just one more issue, when I press the increase or decrease buttons, it shows orange background for the button. Do you know how I can change the background for it?

    thanks a lot

    Jing
  7. Answer
    Dani
    Admin
    Dani avatar
    848 posts

    Posted 02 May 2011 Link to this post

    Hello Jing,

    To change the gradient of the pressed state, you need to generate the Style for the ButtonChrome found in the increase and decrease buttons. The generated ButtonChromeStyle has a Border x:Name="PressedVisual" element. You can change its Background, Border, BorderThickness to your own needs. Again, attached is the modified project.

    Best wishes,
    Dani
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  8. Jing
    Jing avatar
    6 posts
    Member since:
    Jan 2011

    Posted 08 May 2011 Link to this post

    thanks Dani.
Back to Top
UI for WPF is Visual Studio 2017 Ready