Results 1 to 2 of 2
  1. #1
    jmk909er is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Oct 2010
    Location
    San Diego, CA
    Posts
    39

    Change form property with VBA


    When I click in a text box on one form it opens another form using the following code:

    Private Sub Reference_Number_Click()
    Dim stDocName As String
    Dim stLinkCriteria As String
    stDocName = "frmProjects"

    stLinkCriteria = "[Reference Number]=" & "'" & Me![Reference Number] & "'"
    DoCmd.OpenForm stDocName, , , stLinkCriteria
    End Sub

    The problem that I have is that after the form opens, when I click on the record selector on the bottom of the form it just shows one record and if you click forward it comes up with a blank form waiting to be filled in. If I click on "Filtered" right next to the record selector and make it unfiltered then it works fine and I can click through all my other records.

    Question: Is there anything I can add to the code above that will open the form "Unfiltered" and by the way I would also like to disable the add new record next to the selector??

    Thanks, Joe

  2. #2
    jmk909er is offline Advanced Beginner
    Windows Vista Access 2007
    Join Date
    Oct 2010
    Location
    San Diego, CA
    Posts
    39
    Never mind, I see what I'm doing wrong

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

Similar Threads

  1. Change Password form
    By turbo910 in forum Forms
    Replies: 16
    Last Post: 05-07-2015, 09:02 AM
  2. change data form other
    By Balen in forum Access
    Replies: 1
    Last Post: 08-09-2010, 02:44 AM
  3. Pass a form property to a procedure
    By trb5016 in forum Programming
    Replies: 2
    Last Post: 02-17-2010, 04:15 PM
  4. Access 2003, sort order property of a form
    By Rick West in forum Forms
    Replies: 11
    Last Post: 09-17-2009, 08:28 PM
  5. Replies: 1
    Last Post: 08-10-2008, 01:09 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