Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Evaluating Amper vars

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Evaluating Amper vars
 Login/Join
 
Gold member
posted
If I derive programmatically in a FOCEXEC the name of a parameter stored in a launch page, say 'LKUPDE' (without the ampersand), can I get the value of that parameter? What would the syntax be?

Lets pretend that the following -SET statement derives the name of a parameter on my launch page called 'LKUPDE':

-SET &MYPARM = 'LKUPDE';

Now,

-TYPE &MYPARM.EVAL

would produce the text:

LKUPDE

I would like to get the value of the amper variable &LKUPDE.

-TYPE &(&MYPARM.EVAL)

would produce the text:

&(LKUPDE)

Not what I want, and:

-TYPE &&MYPARM.EVAL

tries to evaluate the global amper variable &&MYPARM.

Any suggestions as to how I might get FOCUS to give me the value of &LKUPDE ??

-James
 
Posts: 83 | Location: Dartmouth Hitchcock Medical Center | Registered: April 17, 2003Report This Post
<Thiru>
posted
James,

From what I understand from your post is you are trying to get the value of the LKUPDE from your HTML form. Then assign it to &MYPARM. Try the code below, but now the TYPE will ask you for the value of LKUPDE since this DM command will have the &LKUPDE in this context.

-SET &MYPARM = 'LKUPDE';
-SET &MYPARM = '&' ||'LKUPDE';
-TYPE &MYPARM.EVAL

I dont know this has answered your post.

--Thiru
 
Report This Post
Expert
posted Hide Post
use the escape character
-SET &MYVAR = '&|' | 'MVAR1';
-TYPE &MYVAR
The eval isn't necessary, in this case.
Only if you expect the &var to perform something.
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Gold member
posted Hide Post
use the escape character - this is interesting and produces the desired result!

-SET &MYVAR = '&|' | 'MVAR1';
-TYPE &MYVAR

Does the escape character defer the evaluation of the amper variable until after the concatenation? Is this what is going on?
 
Posts: 83 | Location: Dartmouth Hitchcock Medical Center | Registered: April 17, 2003Report This Post
Expert
posted Hide Post
no, the escape character just tells webfocus that this ampersand is not an ampersand in the Dialog Manager sense, its just a character. It says to wf: "Don't execute it, just read it."
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Virtuoso
posted Hide Post
Just another option ... a little easier to type.

-SET &LKUPDE = 'NOTHING HERE';
-SET &MYPARM = 'LKUPDE';
-TYPE &MYPARM.EVAL
-TYPE &.&MYPARM
 
Posts: 1102 | Location: Toronto, Ontario | Registered: May 26, 2004Report This Post
Expert
posted Hide Post
cool
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Evaluating Amper vars

Copyright © 1996-2020 Information Builders