Error: I don't know German 
I am not seeing where wrong data is being passed.
but since when does a program judge data?
Here's a Type error for you, I think that is what you are looking for.

I am not seeing where wrong data is being passed.
but since when does a program judge data?
Here's a Type error for you, I think that is what you are looking for.
Code: (Select All)
'Beispiel fuer falsche Uebergabe an Prozedur/Funktion - 24. Feb. 2025
Option _Explicit
Declare Function Beispiel(kilowatt As Double) As Double
Dim As Double eingabe
Dim eingabe1$
Print
Print "Kilowatt in PS"
Print: Print
Input "Kilowatt eingeben: ", eingabe1$
Print
Print Using "Das sind ###.## PS"; Beispiel(eingabe1$)
Function Beispiel (kilowatt As Double)
Dim As Double ps
ps = kilowatt * 1.36
Beispiel = ps
End Function
b = b + ...