| re: Need help with forms and applyfilter command
How are you opening the Forms? If from VBA code, you can do one of two
things: Use the WhereCondition argument of DoCmd.OpenForms, or pick up an
SQL string to replace the RecordSource of the Form in the Form's Open Event.
I can't see any need at all to have separate identical Forms, unless you
want to just click them in the Forms tab of the Database window to open the
Form.
Larry Linson
Microsoft Access MVP
"webvigator2k" <webvigator2k@yahoo.com> wrote in message
news:e2d6b262.0312291838.2289c05a@posting.google.c om...[color=blue]
> I have a database that I've converted from 8 seperate tables into one
> cumulative table. instead of having 8 unique tables, there are 8
> different tags now (machine1, machine2 etc) that ID every single
> record. I've created a form, but i'm having a hard time filtering the
> data out (i'm creating 8 seperate forms for each machine which all get
> their data from one main table). so basically, i want the machine1
> form to only show machine1 data, machine2 form to show machine2 data
> etc... this is done through a hidden textbox on the form that holds
> the machineID data.
>
> this is the code i've tried to use:
>
> DoCmd.Applyfilter, "[CumulativeSamplesDatabase].[MachineID] =
> [Machine1Active]"
>
> the idea of the code above was to only bring up records that have
> "machine1active" in the MachineID field.[/color] |