G
Gnowor
So I have a table that has information (phone numbers, emails, etc.) for a
bunch of sales agents. I have a form based on this table. I also have a
table that has the dates of sales for each agent, that appears as a subform
on the main info form.
My problem is that some of these agents are members of a team, and when i
add a date of a sale to one member of the team, I want it to add that date to
all members of the team.
The subform right now has an unbound control that pulls up the dates of
sales, and if you type in new info into that unbound control, it adds a
record for that agent, with the sales date you entered.
I was thinking of using afterupdate to add the records to all members of the
team. I have the if statement, but then i draw a blank as to the code that
would go through, find each member of that team and add the record for them.
the if statement would go like:
if Forms!InfoForm!team <> ""
Do I need to build a query that takes Forms!InfoForm!team as a parameter to
find all members of that team? Once I have that, how to I add the record for
each agent that the query returns?
Advice greatly appreciated! Thanks!
-eD
bunch of sales agents. I have a form based on this table. I also have a
table that has the dates of sales for each agent, that appears as a subform
on the main info form.
My problem is that some of these agents are members of a team, and when i
add a date of a sale to one member of the team, I want it to add that date to
all members of the team.
The subform right now has an unbound control that pulls up the dates of
sales, and if you type in new info into that unbound control, it adds a
record for that agent, with the sales date you entered.
I was thinking of using afterupdate to add the records to all members of the
team. I have the if statement, but then i draw a blank as to the code that
would go through, find each member of that team and add the record for them.
the if statement would go like:
if Forms!InfoForm!team <> ""
Do I need to build a query that takes Forms!InfoForm!team as a parameter to
find all members of that team? Once I have that, how to I add the record for
each agent that the query returns?
Advice greatly appreciated! Thanks!
-eD