Results 1 to 2 of 2

Thread: findfirst command

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Sep 2004
    Posts
    24

    Resolved findfirst command

    im am trying to find some records in a database using

    Data1.Recordset.FindFirst "location=" & "'" & strseek & "'"

    the problem i am having is that the "location" field always changes in the project, though diff names go into the same field , is there a way to code this so that this field can be used with a var instead of the actual field name in the database? example:

    data1.recordset.findfirst "myvar" & "'" & strseek & "'" ???

    this doesnt work but i am just trying to give an example of what i think it SHOULD look like.. thanks in advance to all who reply
    Last edited by boge31; Oct 1st, 2004 at 08:35 AM.

  2. #2
    Frenzied Member vbNeo's Avatar
    Join Date
    May 2002
    Location
    Jutland, Denmark
    Posts
    1,994
    I believe it would be:

    data1.recordset.findfirst yourvar & "='" & strseek & "'"
    "Lies, sanctions, and cruise missiles have never created a free and just society. Only everyday people can do that."
    - Zack de la Rocha


    Hear me roar.

Posting Permissions

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



Click Here to Expand Forum to Full Width