![]() |
[Error] Unit1.pas(50): Type of expression must be BOOLEAN
Hilfe was mache ich hier Falsch?????
procedure TForm1.AbgleichenClick(Sender: TObject); begin ergebnis := StrToFloat (Form1.caption); If VermutungsZahl := FloatToBool (ergebnis); Then ShowMessage(Gewonnen); end; end. Fehlermeldungen: [Error] Unit1.pas(50): Type of expression must be BOOLEAN [Error] Unit1.pas(56): Statement expected but end of file found wieso?kann mir wer helfen? möglichsT schnell mache Praktikum und brauche eine Antwort |
AW: [Error] Unit1.pas(50): Type of expression must be BOOLEAN
Bei Vergleichen benutzt man ein einfaches "=" und kein ":=".
Außerdem gibt es keine FloatToBool-Funktion. PS: Du solltest um deinen Code mit delphi-Tags umschließen, dann wird der Code schöner angezeigt. |
AW: [Error] Unit1.pas(50): Type of expression must be BOOLEAN
Delphi-Quellcode:
If VermutungsZahl = FloatToBool (ergebnis) Then
ShowMessage(Gewonnen); |
Alle Zeitangaben in WEZ +1. Es ist jetzt 00:23 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz