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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to convert a number to a meaningful text in a report 2

Status
Not open for further replies.

lilin

Technical User
Apr 20, 2003
3
0
0
US
Hi,
could anyone let me know the typical way to convert a number into a meaningful text.
for instance, I have a field called "payment", it is inputed by a group option. 1 means "credit card", 2 is "personal check", when I generate a report, instead of displaying number "1" or "2", I hope to display "credit card" or "personal check".

thanks
lin
 
Hi,

I would have a lookup table with a code with your number, and a description field with the full name. This field can be joined in a query and the description printed on your report.

John


John Barnett
--
Please consider awarding me a star if you feel my posting has been useful. Thank you.
 
Or you could create a query using an IIF statement which will convert your text and then base your report on that:

Method:IIf([Address2]=1,"Credit Card","Personal Cheque")

The alias for the column is Method.

This could also possibly be done by amending the control on the form.

Good Luck,

Dan.
 
change the control on the report to a combo box
columns=2
boundcolumn=1
rowsourcetype iif(if you have a table with your payment methods,tablequery,valuelist)
rowsource iif(if you have a table with your paymet methods,"select paymentmethodid,paymentmethod from paymethodtable",1 ;credit card;2;personal check)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top