Wywołanie zdarzenia OnKeyUp

0

Witam,
Dla Tedita pod zdarzeniem OnKeyUp przypisałem procedurę

 procedure licz_sume(Sender: TObject; var Key: Word;
  Shift: TShiftState);
 

Jak mogę ją wywołać w zdarzeniu OnKeyPress ?

0

Po prostu licz_sume(Sender, ..., ...);?

0

OnKeyUp jest "po" OnKeyPress i wywoła się samo. Jeśli musisz z jednego wywołać drugie to znaczy, że coś masz nie tak zaprojektowane

0

Zdarzenie OnKeyUp jest zdarzeniem typu TKeyEvent. Cytat z mojego help'a:

"The TKeyEvent type points to a method that handles keyboard events. The Key parameter is the key on the keyboard. For non-alphanumeric keys, you must use virtual key codes to determine the key pressed. For more information, see Virtual Key codes."

A jeśli tego Word nie będzie w "Virtual Key codes", to jego drugi znak traktuj jako Char w KeyPress. No i uwzględnij to, co masz w "Shift: TShiftState".

W sumie to powinno być "dla początkujących".

1 użytkowników online, w tym zalogowanych: 0, gości: 1