Button/Query/Criteria/OpenRecordForm

  • Thread starter Thread starter vince
  • Start date Start date
V

vince

Hi,

I would like to know if there is a code that will allow me
to create a button that upon click will automatically
query and open a form or record that matches the set
criteria.

For example each of my forms is hard coded with a TransID
thus I would like it if the user clicks the button to
bring up the related record via a form?

Thx a lot!

Vince
 
vince said:
Hi,

I would like to know if there is a code that will allow me
to create a button that upon click will automatically
query and open a form or record that matches the set
criteria.

For example each of my forms is hard coded with a TransID
thus I would like it if the user clicks the button to
bring up the related record via a form?

One of the wizard options for CommandButtons does exactly this. It results in
something similar to...

DoCmd.OpenForm "FormName",,,"[TransID] = " & Me![TransIDFilterValue]
 
Back
Top