Unable to cast object of type ‘System.Int32’ to type ‘System.String’ error

Change the line with invoiceNum to:

invoiceNum = performCommand.GetInt16(0);

Leave a Comment