We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Start editing not only with numbers, but also with minus sign

Thread ID:

Created:

Updated:

Platform:

Replies:

128296 Jan 12,2017 01:07 PM Jan 23,2017 05:56 AM WPF 5
loading
Tags: SfDataGrid
Harald Betzler
Asked On January 12, 2017 01:07 PM

Hi,

I'm able to start editing in SfDataGrid cells by typing the first character or digit.

For entering negative Numbers I would like to start editing with a minus sign. But this doesn't work.

(After typing the first digit a entered minus sign will result in a leading minus sign. That's ok.)

The problem only occurs after selecting a SfDataGrid cell by tab key or arrow keys. 
When selecting a cell by mouse click, the cell is immediately in edit mode, and there is no problem to start with a minus sign.

Regards
Harald

Sivakumar R [Syncfusion]
Replied On January 13, 2017 05:52 AM

Hi Harald, 
 
Your requirement can be achieved by overriding OnTextInput method of SfDataGrid. You can find the code snippet and sample in the below article, 
 
Thanks, 
Sivakumar 


Harald Betzler
Replied On January 15, 2017 11:41 PM

Hi Sivakumar,

thank you. Now the minus sign starts cell editing but it isn't recognized as content.

I have to enter minus sign twice. One to start editing and one to get a negative number.

Regards
Harald

Farjana Parveen Ayubb [Syncfusion]
Replied On January 17, 2017 04:57 AM

Hi Harald, 
 
Sorry for the inconvenience caused. 
 
We have tested the sample which we have provided in the last update, minus sign is recognized as a content we have checked in CurrentCellEndEdit event of SfDataGrid and editing is starts while entering the minus sign first itself. Both the issues are not reproduced on our end, its works as expected. We have tested the sample in latest Syncfusion version  14.4.0.20, could you please share you Syncfusion product version that will help us to provide the better solution. For your reference we have recorded the video and please refer the video  and sample in following location: 
 
Sample Location: CustomizeEditMode_Sample
 
  
Video Location: MinusValue_Video 
Regards, 
Farjana Parveen A 


Harald Betzler
Replied On January 20, 2017 06:33 AM

Hi Farjana,

thank you for the sample.The sample works as expected. 

But not my application. I do not have time to search the reason, because of live going at the end of next week. Maybe the reason is the usage of renderers or template selector or CurrentCellBeginEdit events or ... or ... or ...

Regards
Harald



Jai Ganesh S [Syncfusion]
Replied On January 23, 2017 05:56 AM

Hi Herald, 
 
A support incident to track the status of this feature has been created under your account. Please log on to our support website to check for further updates. 
 
Regards, 
Jai Ganesh S 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;