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!

Convert Text into a Parameter Value

Status
Not open for further replies.

didonato

MIS
Aug 29, 2001
34
0
0
US
I'm using CRX. I'm trying to convert a text string into a paramter VALUE. I've create several parameters, {P1}, {p2}, {P3}, up to {P10}. I have a formaula that generates numbers (1-10) based on an array and tries to convert it into a parameter FIELD. BASIC Example:


xx = 1


======================
"{?p" + xx + "}";
=======================
I want the parameter VALUE of {?P1} to display and when xx = 2 I want the parameter value of {?P2} to display.
The formula is displaying it as TEXT "{?P1}"
 
I don't believe you can do it that way. I think what you'll have to do a long if..then, or you can use a switch statement:

switch(
xx = 1, {?P1},
xx = 2, {?P2},
xx = 3, {?P3}, ....

-Dell

A computer only does what you actually told it to do - not what you thought you told it to do.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top