Results 1 to 7 of 7
  1. #1
    dlewicki is offline Novice
    Windows XP Access 2007
    Join Date
    Dec 2009
    Posts
    11

    No action button

    I have a button which is supposed to load a form on the click event, however, nothing happens. Here's the code...


    Private Sub home_Click()
    On Error GoTo Err_home_Click
    Dim stDocName As String
    Dim stLinkCriteria As String
    stDocName = "sample switchboard"
    DoCmd.OpenForm stDocName, , , stLinkCriteria
    Exit_home_Click:


    Exit Sub
    Err_home_Click:
    MsgBox Err.Description
    Resume Exit_home_Click

    End Sub

    Cna anyone help?

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Do you have a form named "sample switchboard"?

  3. #3
    dlewicki is offline Novice
    Windows XP Access 2007
    Join Date
    Dec 2009
    Posts
    11

    Form name

    Yes, I have a form by that name.

  4. #4
    dlewicki is offline Novice
    Windows XP Access 2007
    Join Date
    Dec 2009
    Posts
    11

    Code

    This piece of code is also being used by other forms (on a button click) to bring it back to the sample switchboard form. The code is working in the other places but not in this place.

  5. #5
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    When you look at the property sheet for the "Home" button, do you see "[Event Procedure]"? Push the "..." button there. Does it take tou to the code? Put a MsgBox in the code to make sure the code is actually executing.

  6. #6
    dlewicki is offline Novice
    Windows XP Access 2007
    Join Date
    Dec 2009
    Posts
    11

    Answer

    Thanks for the help. I found the problem... the security issue button popped up on the database and I granted permissions.

  7. #7
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    That's great! Are you ready to follow the link in my sig and mark this thread as Solved.

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

Similar Threads

  1. Replies: 5
    Last Post: 11-10-2009, 01:16 PM
  2. Replies: 2
    Last Post: 10-01-2009, 03:39 PM
  3. OpenForm Action and Arguments
    By nkenney in forum Forms
    Replies: 9
    Last Post: 04-05-2009, 09:33 AM
  4. Replies: 0
    Last Post: 04-04-2008, 03:43 PM
  5. StopMacros action in 2007
    By jcmartell in forum Programming
    Replies: 0
    Last Post: 04-25-2007, 09:04 AM

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