Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

KeyPressed procedure

Status
Not open for further replies.

Jachimo

Programmer
Aug 24, 2021
1
PL
Hello
I am new to Delphi and am having trouble implementing the KeyPressed procedure. On the Internet I find procedures or functions that respond to 1, 2, or several keys, but I have not found anything that would respond to any key. (Equivalent to the Pascal KeyPressed procedure).
I attach a program fragment in which I want to apply the procedure.

.....
begin

.....

Rx := expr;
if Rx = 0.0 then begin
Memo1.Lines.Add( 'Check why Rx = zero ');
Memo1.Lines.Add( 'Press any Key');
repeat
until KeyPressed);
halt
end;

.....

end;
end.

Please help.
Regards
 
This whole thing looks odd. You typically don't do console control with Windows forms. OP what are you trying to accomplish?

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top