Button/Query/Criteria/OpenRecordForm

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
 
R

Rick Brandt

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]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top