L
LiquidWrench
I use this code in the click event of a cmd button and the append query runs
but appends no records.
Private Sub cmdTrackComplete_Click()
DoCmd.RunMacro "MCR-TrackComplete"
If chkTrackSuccessYes_no <> 0 Then
Me.cmdRecordRemove.Visible = True
Else: Me.cmdRecordRemove.Visible = False
End If
End Sub
When I run just the macro itself from the click event in properties for the
cmd button it works fine and appends the record. I really want to run it
from code so the If Then Else statement will also occur.
Does anyone know why the Append query that is called by the macro will not
append a record when the macro is run from code but when the same macro is
run from the properties/click event directly it will append a the current
record.
The specific message is "You are about to append 0 records"
It should read "You are about to append 1 record"
but appends no records.
Private Sub cmdTrackComplete_Click()
DoCmd.RunMacro "MCR-TrackComplete"
If chkTrackSuccessYes_no <> 0 Then
Me.cmdRecordRemove.Visible = True
Else: Me.cmdRecordRemove.Visible = False
End If
End Sub
When I run just the macro itself from the click event in properties for the
cmd button it works fine and appends the record. I really want to run it
from code so the If Then Else statement will also occur.
Does anyone know why the Append query that is called by the macro will not
append a record when the macro is run from code but when the same macro is
run from the properties/click event directly it will append a the current
record.
The specific message is "You are about to append 0 records"
It should read "You are about to append 1 record"