Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report

Status
Not open for further replies.

eshaan

Technical User
Feb 20, 2003
57
US
Hi all,

I created report. On that report tthere is department name has to show. Data is coming from table with numeric values.

I coded on report depart name
=iff[forms]![frmname]![combobox] ,"2", "financial",or[ forms]![frmname]![combobox] ,'3' "Billing Dept", or,[forms]![frmname]![combobox] ,'4', "Purchase Dept"

I have to code until 9 codes

Is it correct?

Please correct it.

 
this is one way the better way would be to use a table with the values

another alternative would be to look at the choose() function
 
Hi gol4

User is selecting Depart. Number values from the form . When reports prints it has to show Dept Name.

There is other way to use iif function
Can you please provide code how to use choose() function on report colum.

Thanks,
 
choose works like a index. since you dont show a 1 it will return ""

=Choose(forms]![frmname]![combobox], "", "Financial", "Billing Dept", "Purchasing Dept")

keep in mind this only will work on a single select listbox

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top