Is there a way to add a spin Up/Down button in the RadMaskedNumericInput?

4 posts, 1 answers
  1. Sintayehu
    Sintayehu avatar
    67 posts
    Member since:
    Jan 2013

    Posted 22 Aug 2013 Link to this post


    Hello,

    We would really like to use your RadMaskedNumericInput in form fields and inside a RadGridView for cell editing purposes.

    Masking, formatting, spinning are all important features for us.

    Spinning with up/down key press works beautifully but we would like to see if there is a way to add up/down spin buttons to make this feature more visible and friendlier to the user.

    I know there is a RadNumericUpDown control that has this out of the box but it doesn't have the features that the Masked editor gives us.

    Look forward to your suggestion.

    Thanks!
  2. Sintayehu
    Sintayehu avatar
    67 posts
    Member since:
    Jan 2013

    Posted 22 Aug 2013 Link to this post

    After writing this I figured I re-template the control.

    So I extended the RadMaskedNumericInput and added Two RepeatButtons in the RadMaskedInputBase Template much like the RadNumericUpDown does.

    And from My custom control I handle the RepeatButtons Increase and decrease events by calling the base CallSpin(tru/false)
    method.

    That seems to work for now. But please let me know if there is a simpler way, like "Oh just set The ShowButton attribute to true".

    It will be also helpful to know why you guys didn't add these buttons, in case there is a negative reason.

    Thanks!

  3. DevCraft banner
  4. Answer
    Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 27 Aug 2013 Link to this post

    Hi Sintayehu,

     I believe you have started a good approach for achieving this functionality. Usually these buttons are placed in controls (for example Numeric UpDown) where you have limited options (for example values 1-10) and operations like incrementing/decrementing with one are the most typical. On the other hand MaskNumericInput / CurrencyInput are typically used to store big double / decimal numbers and it is rare to set them a minimum / maximum values or set them a some period or set of valid numbers. The most typical scenario is editing the current value to some other value and then save, then input another value. Incrementing / Decrementing is more uncommon operation and that is why up/down buttons are not included in the default template by design.

    Regards,
    Petar Mladenov
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  5. Sintayehu
    Sintayehu avatar
    67 posts
    Member since:
    Jan 2013

    Posted 04 Sep 2013 Link to this post

    Thanks, I went ahead and created the spin buttons and it works as expected , I had to put focus back into the control on every repeat button click after calling CallSpin(tru/false).
Back to Top