Lazarus

Free Pascal => Beginners => Topic started by: ThomasD on January 05, 2022, 05:23:33 pm

Title: How to read char from keyboard (was Bitte lesen ist wichtig danke)
Post by: ThomasD on January 05, 2022, 05:23:33 pm
Hallo liebe Pascal Benutzer,
Ich habe eine Anfängerfrage.
Wie kann ich ein Zeichen von der Tastatur direkt lesen ohne das Zeichen mit Enter
annehmen zu müssen?
Vielen Dank im voraus Thomas

[Edit]
Hello dear Pascal users,
I have a beginner question.
How can I read a character from the keyboard directly without having to press Enter first?
Thank you in advance Thomas
[/Edit]
Title: Re: Bitte lesen ist wichtig danke
Post by: wp on January 05, 2022, 05:30:45 pm
Du bist hier im englisch-sprachigen Forum. Bitte übersetze die Frage auf Englisch, oder poste im deutschen Lazarus-Forum: https://www.lazarusforum.de/app.php/portal
Title: Re: Bitte lesen ist wichtig danke
Post by: Bart on January 05, 2022, 05:52:09 pm
In the console you can if you use crt unit and then use something like AChar := ReadKey.

Bart
Title: Re: Bitte lesen ist wichtig danke
Post by: PascalDragon on January 06, 2022, 01:14:03 pm
Du bist hier im englisch-sprachigen Forum. Bitte übersetze die Frage auf Englisch, oder poste im deutschen Lazarus-Forum: https://www.lazarusforum.de/app.php/portal

In addition to what wp said (no matter if you translate your post or ask on the German forum): use a better title. “Please read, it's important, thank you” is just “click bait” or something like that. The title should be a very short description of your problem.
TinyPortal © 2005-2018