Delete checked item (one or more) from listview I write this code.
Dim x As Long
For x = LVEmp.ListItems.Count To 1 Step -1
If LVEmp.ListItems(x).Checked Then
con.Execute "DELETE FROM stock WHERE [SrNo] = '" & LVEmp.ListItems(x).SubItems(1) & "'"
LVEmp.ListItems.Remove x
End If
Next
con.Close
Set con = Nothing
but it show error massage:
run time error -2147217913 (80040e07)
data type mismatch in criteria expression.