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.
Frank, Tex is right, you can't DEFAULT one &var with the value of another &var. tant pis. so, you must create a new variable with -SET which accepts the incoming value of the DEFAULTed var, and proceed to make all your decisions from that second var.
In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003
I want to show the precalculated value of the amper variable to the user and the user must have the opportunity to overrule that value
So when the program runs this month the prompt show '20070101' and the user might change that in 20061201 or 20050501. Next month (march) the program automatically show '20070201' and either the user hits run and the program uses that value or again the user over wrights that value to '20060301'.
What Tex suggests is easy to do, but that "somevalue" is static and I want that value variable.
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
In that case you need to do something with javascript. I have several launch pages at a customer site that set a Default date range of 2 variables. the user can changes the values and then submit the request.
I think I understand your problem. If you are using the autoprompt screen I'm sure it will never work. Some months ago I had the same problem and came to the following conclusion. The reason why this will never work with the autoprompt screen is because the &var's are never checked or resolved before the autoprompt screen is constructed. There is no instruction or funtion or whatever to tell Webfocus that an &var should be resolved before it prompts for other &vars. It simply cannot be done with autoprompt.
If you realy need this you should create your own html parameter screens.
If &COMPUTEDVALUE contains 99, then &TEXT will contain '-DEFAULT &X=99' which is a valid DEFAULT statement. Presto, the 'static' syntax of DEFAULT is now has content that will differ with each run.
Chris Burtt
WIN/2K running WF 7.6.4 Development via DevStudio 7.6.4, MRE, TextEditor. Data is Oracle, MS-SQL.
Posts: 154 | Location: NY | Registered: October 27, 2005
Sorry, but as far as I know, this cannot work with autoprompting. If you use this code in a autoprompt you will get &YYMD.EVAL in the textbox and not the current date like 20070206. This is due to the fact that the variables are not resolved before prompting. There is no way to tell WebFOCUS if it needs to prompt for the variable or to resolve the variable.
Frank, Have this issue been resolved? This has been my problem since I use WF for reporting. I was thinking about using the fex to return the calculated date in XML file for the HTML &variable, but don't know how to allow users to override the value.
Developer Studio 7.6.11 AS400 - V5R4 HTML,PDF,XLS
Posts: 305 | Location: Winnipeg,MB | Registered: May 12, 2008
No it is not. But I have seen a smart workaround that I need to workout.
The idea is to create overnight a small text file that holds the line -DEFAULT &PERIODE='200812'; (the actual month ore the date you want it it to be)... Now this small file comes in place of the code line in your fex, with an INCLUDE. If the user runs the program by default the auto prompted value will be this value but the user can change it.
If you need only ones something like this, this can be done, but if you need 10 or 20 different values you have to create 10 or 20 different include files.
The daily or monthly creation of this files wont be to difficult.
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
Thanks for the work around solution. It will be good enough for a single application.
I am thinking this would be tricky to re-use these text files for different applications. I mean that 200812 may be the &ENDING_PERIOD in one application and is meant for the &CURRENT_PERIOD for the next application; And the default value for &FROM_DATE in monthly report will be different from the annual repport. So managing these files can be quite challenge as they will affect how we name the variables in the applications.
Hua
Developer Studio 7.6.11 AS400 - V5R4 HTML,PDF,XLS
Posts: 305 | Location: Winnipeg,MB | Registered: May 12, 2008