Pedro Janssen
pedro at plex.nl
Tue Jul 8 10:03:43 CDT 2008
Dear AccessD members,
its has been a long time ago since i asked for your help, but now i need it.
I have a form on which i do some calculations.
After the calculation, i want to delete the data with a deletequery through a macro. But when i have done that in the textbox the text: #Deleted# is shown.
I have tried to refresh the form, with no result.
Because of that i now, delete the data and close and re-open the form, by the code below.
Sometimes however the inputfield are empty, and sometimes they aren't.
How is that possible.
Or is there a better way to do this.
Thanks
Pedro Janssen
Private Sub cmdDelete_Click()
On Error GoTo Err_cmdDelete_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "mcrDelete"
DoCmd.RunMacro stDocName
DoCmd.Close
stDocName = "frmBerekenen"
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_cmdDelete_Click:
Exit Sub
Err_cmdDelete_Click:
MsgBox Err.Description
Resume Exit_cmdDelete_Click
End Sub