Moin und

im Forum!
Du kannst statt
StrToInt/Float auch
StrToIntDef(Str,Vorgabe) bzw.
StrToIntFloat(Str,Vorgabe) verwenden, dann wird ein Standardwert (-> Vorgabe) verwendet, wenn die Zeichenkette sich nicht umwandeln lässt.
Ansonsten ist der Ansatz mit try-except schon OK, die IDE zeigt aber - wenn du es nicht explizit in den Umgebungsoptionen ausschaltest - trotzdem Exceptions an. Wenn du das Programm direkt (also ohne die IDE) startest, dann wird keine Exception mehr ausgelöst.
cu
Narses
There are 10 types of people - those who understand binary and those who don´t.