Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2002

    Unanswered: how to display a record in a form based on results of a query

    I have a small database with inventory information.
    I would like the form to update with record information based on a form's data.

    For example:
    a part with serial number 1 is to be checked out. how do I make the form update with all of the pertinent record data with a LostFocus() method based on the entered serial number data in the serial number space of the form?

  2. #2
    Join Date
    Feb 2002
    I take it from your title you have a query that returns the records.

    Open the query in design view, click on the design view button adn choose SQL view from the drop down list.

    Open a new form in design view, go to the Properties window and click the ellipsis for the recordsource. This will open a query window. Change the query window to SQL view and choose paste. Clsoe out of here back to form design view and click on the field list. All your fields should be there. Copy the fields as required to our form.

    In the Onchange event of serial number, put a command to oepn the form created above. This will default to the record your query defaults to.

    Alternative Method

    You could create a combo box with the wizard in the header of the form, and use the wizard to find the corresponding record.

    Alternative MEthod

    You could create a subform and relate the serial numbers as the linking fields.

Posting Permissions

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