1

I have a windows form with Gridex Control which hangs when the 'Enter' key is pressed when editing a row. The 'Enter' key triggers 'EndCustomEdit' event and the win forms freezes.

Is there a way I can disable the triggering of 'EndCustomEdit' event while the enter key is pressed?.

I tried implementing Gridex 'EnterKeyBehavior' property inside 'EndCustomEdit' event and tried setting it to none value but didn't see the required result.

this.gexContributor.EnterKeyBehavior = EnterKeyBehavior.None;

The other possibility i can think of is to create keyDown or KeyPressed event handler and handles the enter key behavior.

Plz let me know your thoughts. Thanks in advance :)

  • It sounds like it could be getting hung-up on the UI thread when it goes to re-draw the UI after EndCustomEdit. Make sure there is no code running that has locked the UI thread. – bPuhnk Jan 19 '21 at 17:18

1 Answers1

1

Following setting

this.gexContributor.EnterKeyBehavior = EnterKeyBehavior.None;

at the designer.cs level would fix this issue.

help-info.de
  • 6,695
  • 16
  • 39
  • 41
  • Please have a look at [Can I answer my own question?](http://stackoverflow.com/help/self-answer) and come back two days later and check as answered if you have more than 15 reputation (See also: [Accept Your Own Answers](https://stackoverflow.blog/2009/01/06/accept-your-own-answers/). – help-info.de May 28 '21 at 15:16