Results 1 to 4 of 4
  1. #1
    2 Star Lounger
    Join Date
    Apr 2005
    Location
    Plovdiv
    Posts
    109
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Find First (Access 2000)

    i fail to open a form because in the find first code the client is not on the first place.Can you help me rewrite the command so that to find the right client with the code ?The command is :
    Dim rs As DAO.Recordset
    Set rs = Me.RecordsetClone
    rs.FindFirst "[ClientID] = " & List65.Value
    If rs.NoMatch Then
    MsgBox "Client Not Found"
    Else
    Me.Bookmark = rs.Bookmark
    End If
    and i want to find the client hat has this offer

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Find First (Access 2000)

    Where is this code? How does it fail to open a form? I see nothing that opens a form.

  3. #3
    2 Star Lounger
    Join Date
    Apr 2005
    Location
    Plovdiv
    Posts
    109
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Find First (Access 2000)

    I am sorry i am resending it again.Actually i wanted to open the same form but for the customer that has this offer.I want to find it by clicking on the offer number from the list box

  4. #4
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Find First (Access 2000)

    In the query behind the list box, put clientID in the first column rather than the third. It is the first column that provides the value of the listbox, and you are using the value of the listbox for the find.

    I would move the code to the double click event. With the click event people will execute the code when they don't intend to.
    Regards
    John



Posting Permissions

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