Results 1 to 2 of 2
  1. #1
    mugsmugs is offline Novice
    Windows XP Access 2003
    Join Date
    Feb 2009
    Location
    Philadelphia, PA
    Posts
    3

    Error 28: Out of Stack Space??

    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

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    In the following part of your code:
    Code:
    Set Qd = Nothing
    Command226_Click
    ...The RED code is recursively calling the code that is already executing!

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Export to RTF is creating white space at end of page
    By Sherri726 in forum Import/Export Data
    Replies: 0
    Last Post: 12-19-2006, 03:24 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums