Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
925
Some issues with XamNumericInput
posted

Hi,

I use the XamNumericInput control with following settings.

 

 

 

 

 

 

 

 

 

this.Mask = "nnnnnnnnnnnnn.nnnn";

 

 

 

this.PromptChar = new Char();

 

 

 

this.TrimFractionalZeros = true;

 

 

 

this.DisplayMode = InputMaskMode.Raw;

 

 

this.DataMode = InputMaskMode.Raw;

1. The property "SelectionStart" don`t show the correct cursor position.

2. When the cursor is at the end or begin of the text, I can`t move the cursor with the arrow keys.

3. Type "123.123" in the textbox. Select all characters with the mouse from right to left in the textbox and delete the selected text. Now the XamNumericInput control shows ".1".

 

I believe, the XamNumericInput control have problems when the prompt char is empty.

 

Regards

Marco

Parents
  • 34510
    Offline posted

    Hi Marco,

    280872 said:
    3. Type "123.123" in the textbox. Select all characters with the mouse from right to left in the textbox and delete the selected text. Now the XamNumericInput control shows ".1".

    I'm not seeing the same behavior you are for this.  When I enter in the numbers 123.123 then select all characters with the mouse from right to left and press Delete, all the characters are deleted normally.  Are there any other settings you have applied to the XamNumericInput, maybe in your XAML?

    280872 said:
    2. When the cursor is at the end or begin of the text, I can`t move the cursor with the arrow keys.

    I think what you're seeing is that the caret is still taking into account the empty spaces created by having an empty PromptChar so it looks like the cursor is stuck.  I'm going to research this and see if theres a way you can restrict the caret position so that it does not travel past actual text.

    280872 said:
    1. The property "SelectionStart" don`t show the correct cursor position.

    How and where are you setting the SelectionStart property?

Reply Children