Change data with drop list

johnob

Registered User.
Local time
Today, 17:29
Joined
Jan 12, 2014
Messages
45
Hi all,

I have a drop down list with the following : Week And Weekend :. I want to change the Average field depending what is selected. But having a problem.

I'm using the below code, but does not work

Code:
=IIf([Days select]="Weekend", [Reports]![Weekend Settings]![Average),([Reports]![Week Settings]![Average])
Can anyone help

Thank You
 
Last edited:
... "but does not work" isn't really an error explanation, is it? So what (error) do you get?
Where do you have your code and how do you trigger it?
Do you have both reports open?
 
hi

both reports are open , the error is that the value does not change when you select from the drop list
 
Sorry I see some error maybe some typo:
=IIf([Days select]="Weekend", [Reports]![Weekend Settings]![Average),([Reports]![Week Settings]![Average])
Correct:
=IIf([Days select]="Weekend", [Reports]![Weekend Settings]![Average],[Reports]![Week Settings]![Average])
 
hi

sorry thats my typo, correct code
=IIf([Days select]="Weekend", [Reports]![Weekend Settings]![Average],[Reports]![Week Settings]![Average])
 
Okay.
I feel it would be a long thread, so I've made some sample for you in the attached database.
Open first the 2 reports, then the form, do some selection in the listbox.
 

Attachments

Users who are viewing this thread

Back
Top Bottom