Reference Frame Selection in report

jemar707311

Registered User.
Local time
Today, 16:01
Joined
Aug 1, 2001
Messages
14
I have a report based on a query that is sorted by a user selection in a frame on a form.......make sense?
here is the problem.
On the report, I want a text box to show what the user selected as the sort order and display it.
I used a text box to look at the frame on form as follows:
=[Forms]![frm_Search_Results]![Frame2]
However, it only show the option # i.e "3" instead of the option label. How do I do this?
 
Use an =iif statement in your text box to check the value of the frame. Then refer to the caption of the corresponding label. For example, if you have two choises and the labels are Label5 and Label7

=iif(forms!frm_x!frame3 = 1, forms!frm_x!Label5.caption, forms!frm_x!Label7.caption)

If you have several choices, you can nest your iif statements.

Good Luck, CedarSam
 
Take a look at the Choose() function in Access help. This will do exactly what you want.

HTH
RDH
 

Users who are viewing this thread

Back
Top Bottom