Gotorecord Where Equal

  • Thread starter bhipwell via AccessMonster.com
  • Start date
B

bhipwell via AccessMonster.com

I need to put a button that allows the user to move to the next record. On
the form, I have a list of employees that are filtered by the company they
work for.

Obviously, if I use the simple Gotorecord command, it will pull up the next
record regardless of what company that employee works for. So...

1) I need the button to take the user to the next record where the company
(field is CompanyID) matches the company on the form.

2) I need the list box that displays the employees specific to the company,
to highlight/select the employee to which the next record function takes them.


Thanks in advance!

B
 
G

Guest

B,

Wouldn't it be easier to set a filter after you've chosen a certain company?
That way you would only get the records which are tied to that company. When
done remove the filter.

Could be something like:

me.filter="CompanyID= " & me.combobox '-replace with your own
me.filteron=true

when done

Me.filter=""
me.filteron=false

hth
 
B

bhipwell via AccessMonster.com

I had a list box that was filtering for employees associated with a company
choosen on a previous form. I went back and set the entire form to filter
out for this information needed. Although your specific solution wasn't
applicable, it lead me down the right path. Thanks!

B
 

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