vb datagridview with unbound column
Posted on 2013-12-04
I have a datagridview in an application that displays open invoice amounts. I'm storing data in an MS SQL database. I created an unbound column for entry of payment amounts against an open invoice. Upon "submitting" a process is run that applies the payment amount against the open invoice and this works fine. However, if the user has entered an incorrect payment amount and hits delete to clear the field an exception is thrown, system.formatexception, "input string not in a correct format". I have not been able to find a way to prevent this from happening.