Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2004

    Unanswered: how to navigate a searched value through fields on the same form

    Hi, how can I search the same value in all the fields that exist on a form and then continue searching the same value through out the records for all these fields. I know I can use the find and replace function however I cant set the Look In field to use the form as default, as if you click on a control then the Look In field changes to this control. I need the look in field to always remain the form, the code used is:
    Private Sub cmdsearchIndex_Click()
    On Error GoTo Err_cmdsearchIndex_Click
    DoCmd.DoMenuItem acFormBar, acEditMenu, 10, , acMenuVer70

    Exit Sub

    MsgBox Err.Description
    Resume Exit_cmdsearchIndex_Click

    End Sub

    Can someone please advise how this code can be altered so I can have this functionality or provide an alternative suggestion...Thanks

  2. #2
    Join Date
    Oct 2003
    You have two tasks athand one to search the reqd value in the form and the second is to search the table.

    For the frist one, create a form collection to go through all the controls on it and check their value.

    for second, create a tabledef and then run a search on it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts