Format Exception Error

Zenerdiode

Active Member
Licensed User
As part of an application (I want the user to be able to use fingers instead of the SIP) I have built a keypad. This is to input a decimal value and a tollerance of between 0 & 50%. On pressing 'Enter' it populates the button and the button value is used elsewhere.

If the textbox is cleared with the 'C' button and 'Enter' is pressed; in the IDE debugger pressing 'Enter' does nothing - this is what I want. However when Optimised Compiled, on the Device it gives a 'FormatException' or on the desktop it gives 'Input string was not in a correct format'

Where am I going wrong?
 

Attachments

  • Keypad.sbp
    3.7 KB · Views: 174

efc_dev

Member
Licensed User
Longtime User
An optimised App could not handle a comparison with a null value.

For example
' myValue comes from a dataset or something else
' if myValue has got a null value this returns an error

if myValue>0 then ' <-- Format Exception

' do something
end if
 
Top