+ Reply to Thread
Results 1 to 3 of 3

Select Record in form by referencing Integar

  1. #1
    Forum Contributor
    Join Date
    09-23-2007
    Location
    Melbourne, Australia
    Posts
    176

    Wink Select Record in form by referencing Integar

    Does anyone know how to select a record in a form by using an integar.

    I can change a textbox to contain the record number by using the below code

    Please Login or Register  to view this content.
    But I can't change the record in the form by using a record number.

    I would have thought that it would go something like the below but it looks like a 'Record' property doesn't exist. Anyone know if there is a way of doing this? I'm using Access 2002.

    Please Login or Register  to view this content.
    Thanks.
    Last edited by danny2000; 07-21-2011 at 04:38 AM.

  2. #2
    Forum Expert davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2010
    Posts
    1,884

    Re: Select Record in form by referencing Integar

    You need to use SQL or VBA with recordsets to update the underlying value. In general, a SQL statement will be easiest, something like this:

    Please Login or Register  to view this content.
    You can execute this in VBA by using the DoCmd.RunSQL method.
    Is your code running too slowly?
    Does your workbook or database have a bunch of duplicate pieces of data?
    Have a look at this article to learn the best ways to set up your projects.
    It will save both time and effort in the long run!


    Dave

  3. #3
    Forum Contributor
    Join Date
    09-23-2007
    Location
    Melbourne, Australia
    Posts
    176

    Re: Select Record in form by referencing Integar

    Dave, thanks very much. Good solution too.

    I'll definitely use that. Thanks again.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1