Private Sub cmddelete_Click()Dim a As IntegerIf renzheng() ThenIf Adodc1.Recordset.RecordCount = 0 ThenMsgBox "暫時(shí)沒有消費(fèi)記錄!"Exit SubEnd Ifa = MsgBox("刪除后無法恢復(fù)!確認(rèn)要?jiǎng)h除該記錄嗎?", vbYesNo + vbInformation, "警告信息")If a = vbYes ThenAdodc1.Recordset.DeleteAdodc1.Recordset.UpdateBatchIf Adodc1.Recordset.RecordCount = 0 ThenMsgBox "暫時(shí)沒有消費(fèi)記錄!"Exit SubEnd IfIf Adodc1.Recordset.EOF ThenAdodc1.Recordset.MoveLastElseAdodc1.Recordset.MoveNextIf Adodc1.Recordset.EOF ThenAdodc1.Recordset.MoveLastEnd IfEnd IfMsgBox "恭喜您!刪除成功!"End IfElseMsgBox "身份認(rèn)證失敗,密碼錯(cuò)誤!"End IfEnd Sub
生成exe 后提示運(yùn)行的錯(cuò)誤'5',無效的過程調(diào)用或參數(shù)?
函數(shù)式編程
2022-08-11 11:07:22