Hi, I'm new to access and I made an autoform from a table, and I want to be able to update any of the fields using an update button.
The code I put in the button is below, but I am getting an Error 28: Out of Stack Space?
I'm quite sure I'm not doing this correct as it is, but I don't know why i'm getting this error from this either.
Any help would be greatly appreciated...
Private Sub Command226_Click()
On Error GoTo Handler
Dim msg As String
Dim Qd As QueryDef
Dim ItemNumber As String
Dim Change As String
DoCmd.SetWarnings False
Change = Me.lblDesc.Value
ItemNumber = Me.CmbItem.Value
Set Qd = CurrentDb.QueryDefs("qryItemDetailEntry")
With Qd
.Parameters("nItemNumber") = ItemNumber
.Parameters("nDescription") = Me.lblDesc.Value
.Execute
End With
Set Qd = Nothing
Command226_Click
'DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
Handler:
If Err.Number <> 0 Then
msg = "Error " & Str(Err.Number) & ": " & Err.Description
MsgBox msg
End If
End Sub