Article

From:
To:
Ralph Friedman (TeamB)
Subject:
Re: without HTML again
Newsgroup:
borland.public.install.delphi

Re: without HTML again



"
Hello,

I want to simulate a keypress-event for an application. The background is to get keyboard on crt build of buttons for use on a touchscreen system without any hardware-keyboard.
My idea is to simulate a keypress-event. So I desided to use the keypress-procedure of TWinControl which generates an OnKeyPress event.
Is it possible to read the first Char of TButton.Caption and send it via keypress-event to a TEdit.text. My idea is to
procedure TForm1.Button1Click(Sender : TObject); VAR myChar : Char; begin   if (Sender is TButton) then begin     Edit1.setFocus;     myChar := (Sender as TButton).Caption[1];
    KeyPress(myChar); { ???????? }
  end; end;
Has anyone an idea for this problem????? Thanks a lot!
Alex
FYI: The plus sign, '+', may be used to include a word in a search (e.g. +delphi -database). Using the plus sign is optional. If not present, it is assumed.
 
 
Originally created by
Tamarack Associates
Mon, 20 May 2024 01:48:44 UTC
Copyright © 2009-2024
HREF Tools Corp.