M
magmike
I have a button that adds a new record to a table (see code below). Of
course, before doing it, a message box pops up telling me I am about
to append 1 row(s) with a yes no button.
Is there a way to code the button, so that the Yes/No message box does
not happen or to automatically send Yes to that function?
Thanks in advance!
the button code:
Private Sub AddStatus_Click()
Dim stSQL As String
Dim stControl As String
stSQL = "INSERT into Status (StatusCompany, StatusCode) values ([ID],
[StatusCodeTemp])"
stControl = "StatusCodeTemp"
DoCmd.RunSQL stSQL
DoCmd.GoToControl stControl
DoCmd.RunCommand acCmdRefresh
End Sub
magmike
course, before doing it, a message box pops up telling me I am about
to append 1 row(s) with a yes no button.
Is there a way to code the button, so that the Yes/No message box does
not happen or to automatically send Yes to that function?
Thanks in advance!
the button code:
Private Sub AddStatus_Click()
Dim stSQL As String
Dim stControl As String
stSQL = "INSERT into Status (StatusCompany, StatusCode) values ([ID],
[StatusCodeTemp])"
stControl = "StatusCodeTemp"
DoCmd.RunSQL stSQL
DoCmd.GoToControl stControl
DoCmd.RunCommand acCmdRefresh
End Sub
magmike