Jump to content


Photo

TuniEdit - Backspace makes no event

tuniedit keypress event

  • Please log in to reply
2 replies to this topic

#1 vbdavie

vbdavie

    Advanced Member

  • Members
  • PipPipPipPip
  • 108 posts

Posted 24 August 2015 - 02:00 PM

I have a TuniEdit with an OnKeyPress event. It seems to work fine and get all the chars I'm interested in including the CR<#13>.

 

HOWEVER, it appears that the BACKSPACE<#08> character is totally ignored. So, basically, my event never gets called when the user is using the backspace to ALTER the contents of the field.

 

Luckily, the onChange event DOES happen as I change the edit field with the backspace key. Very wierd the that OnChange recognizes the keypress, but the OnKeyPress does NOT.

 

Am I missing something?

 

Davie


  • 0

#2 Delphi Developer

Delphi Developer

    Advanced Member

  • Moderators
  • 5199 posts

Posted 24 August 2015 - 05:20 PM

Hi,

 

You should handle the onKeyDown instead of the onKeyPress event.

 

Best regards.


  • 0

#3 vbdavie

vbdavie

    Advanced Member

  • Members
  • PipPipPipPip
  • 108 posts

Posted 24 August 2015 - 05:33 PM

I suppose that makes sense. Is it because the browser won't send it as a normal key press? Just like it doesn't send the CR as a normal keypress?

 

Davie


  • 0





Also tagged with one or more of these keywords: tuniedit, keypress, event

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users