Run-time error '440': automation error
Run-time error '-2147217833 (80040e57)': arithmetic overflow error converting numeric to data type numeric.
Then the POS shuts down. The only thing we did yesterday between the time it was working and when it stopped working was add some new items to the database, re-indexed the database, and created a backup.
Here is the code that it is erroring out on:
Private Sub Form_Load() 'On Error Resume Next Frame4.Visible = False chkYes.Visible = False chkNo.Visible = False chkEzNo.Value = 1 chkPmNo.Value = 1 chkDepNo.Value = 1 glbSqlStr = "SELECT ItemLookupCode, ID, Description, ExtendedDescription, SubDescription2, DepartmentID, CategoryID FROM Item WHERE DepartmentID IN (20, 21, 22, 23, 24, 25) AND (SubDescription2 = '' OR SubDescription2 = " & glbItemLookUpCode & ")" glbConnStr = "Provider=SQLOLEDB.1;Password=sql;Persist Security Info=True;User ID=sa;Initial Catalog=mytestdb;Data SourceΚRROLLRETAIL" Set glbDbConn = New ADODB.Connection glbDbConn.Open glbConnStr Set glbRecSet = New ADODB.Recordset glbRecSet.Open glbSqlStr, glbDbConn, adOpenKeyset, adLockOptimistic, adCmdText KeyPreview = True If glbCashier = 64 Or glbCashier = 52 Then cmdCancel.Visible = True End If End Sub
any help would be greatly appreciated thank you,