Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Display different variable options for -DEFAULT
Go
New
Search
Notify
Tools
Reply
  
[SOLVED] Display different variable options for -DEFAULT
 Login/Join
 
Silver Member
posted
Hi Fellow Focusers,

Wondering how to display different variable options for -DEFAULT in the 8202 version. Please see screenshot from IBI video. I would like to know the procedure (fex) code to display options like the Store Type. Thanks for any help.

This message has been edited. Last edited by: FP Mod Chuck,


WebFOCUS App Studio 8202M
Windows, All Outputs
 
Posts: 34 | Registered: May 22, 2014Reply With QuoteReport This Post
Virtuoso
posted Hide Post
This is a feature called Page Designer. When you place a fex with parameters inside a page it'll create these controls for you automatically. By default they're all drop down boxes but you can right click and change them.


WebFOCUS 8203, Unix, Windows
 
Posts: 1315 | Location: New York City | Registered: December 30, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
Thanks BabaNYC, that much I know. I am creating using the Page designer. I would like to know what code brings those options up in the Page Designer OR how do I do it in the GUI (then I can look at the code it produces)


WebFOCUS App Studio 8202M
Windows, All Outputs
 
Posts: 34 | Registered: May 22, 2014Reply With QuoteReport This Post
Virtuoso
posted Hide Post
In the GUI, you let Page Designer create all the drop downs and right click and convert. The choices are Radio Buttons or Button Set. I'm not sure what code is generated in the background though.


WebFOCUS 8203, Unix, Windows
 
Posts: 1315 | Location: New York City | Registered: December 30, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
quote:
choices are Radio Buttons or Button Set

Hmmm I'm trying but not seeing those choices. Anyone has a CAR FILE example with options like this?


WebFOCUS App Studio 8202M
Windows, All Outputs
 
Posts: 34 | Registered: May 22, 2014Reply With QuoteReport This Post
Virtuoso
posted Hide Post
quote:
I would like to know the procedure (fex) code to display options like the Store Type

The displayed values are probably coming from a distinct list on possible value within the StoreType field.

As per example using
TABLE FILE CAR
BY COUNTRY
ON TABLE PCHOLD FORMAT XML
END
-RUN

Is giving you all possible Country values that you can then use to have your control populate with.
You then set the control type as you wish : drop down, list box, radio, ...

Is that what you're looking for


WF 7.7.05M, 8.1.05M, 8.2.0.1M gen240 Windows, HTML, Excel, PDF
In Focus since 2007
 
Posts: 1798 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Reply With QuoteReport This Post
Virtuoso
posted Hide Post
Maybe this is an 8203 feature. I don't think the data makes a difference.


WebFOCUS 8203, Unix, Windows
 
Posts: 1315 | Location: New York City | Registered: December 30, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
quote:
The displayed values are probably coming from a distinct list on possible value within the StoreType field.

I have a feeling you are right about this one. I believe it should be an 8202 feature because that the version I found the video under. If I cannot solve it, I will let the users type in textbox 1 of 3 options. Its not ideal but it works.


WebFOCUS App Studio 8202M
Windows, All Outputs
 
Posts: 34 | Registered: May 22, 2014Reply With QuoteReport This Post
Virtuoso
posted Hide Post
quote:
I have a feeling you are right about this one. I believe it should be an 8202 feature because that the version I found the video under. If I cannot solve it, I will let the users type in textbox 1 of 3 options

Create your own choice list.
It doesn't have to come from an existing data table.
You can build any list you want.
Don't let user type what ever they want. If you can provide specific choices, do it. That way you'll be able to control what they select.


WF 7.7.05M, 8.1.05M, 8.2.0.1M gen240 Windows, HTML, Excel, PDF
In Focus since 2007
 
Posts: 1798 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Below is an example fex on the WF_Retail master file that will bring in the controls that you have showing in your picture dynamically from the master file. I also added in my own parameter (&MYLIST) with hard coded options that will display to the end user but the values are stored in the parameter.

Once the controls are created in the page designer as drop-downs, just right-click on the drop-down and select convert to change to a radio or push button control. In that right click menu, there is also a settings choice that will allow you to modify the control (like adding in an 'ALL' option).
  
-DEFAULT &MYLIST = VALUE2;
-SET &MYLIST = &MYLIST.(<DISPLAY1,VALUE1>,<DISPLAY2,VALUE2>,<DISPLAY3,VALUE3>).Choose One.;

TABLE FILE wf_retail
SUM REVENUE_US
BY BUSINESS_REGION
BY PRODUCT_CATEGORY
BY STORE_TYPE
BY TIME_DATE
WHERE BUSINESS_REGION EQ &BUSINESS_REGION.(OR(FIND BUSINESS_REGION IN WF_RETAIL |FORMAT=A15V)).Region:.QUOTEDSTRING;
WHERE PRODUCT_CATEGORY EQ &PRODUCT_CATEGORY.(OR(FIND PRODUCT_CATEGORY IN WF_RETAIL |FORMAT=A40V)).Category:.QUOTEDSTRING;
WHERE STORE_TYPE EQ &STORE_TYPE.(FIND STORE_TYPE IN WF_RETAIL |FORMAT=A11V).Store Type:.QUOTEDSTRING;
WHERE TIME_DATE FROM &FROM_DATE.(|FORMAT=YYMD).From:.QUOTEDSTRING TO &TO_DATE.(|FORMAT=YYMD).To:.QUOTEDSTRING;
ON TABLE PCHOLD FORMAT HTML
ON TABLE SET PAGE-NUM OFF
ON TABLE SET STYLE *
TYPE=REPORT,GRID=OFF, LINES-PER-PAGE=UNLIMITED,  $
ENDSTYLE
END
-RUN


Hallway
WF(Prod):8202M
WF(Test):8202M
OS/Platform:Win 10
Outputs:All
 
Posts: 217 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015Reply With QuoteReport This Post
Silver Member
posted Hide Post
Thanks everyone! I figured it out!! Smiler

I created a table/synonym with my options and tied it into my fex WHERE statement. That gave me the dropdown option in the Page Builder GUI. It doesn't look like the picture I uploaded above with the 3 options side by side (that may be version 8203) but the dropdown option is perfect as users wont have to type anything in.


WebFOCUS App Studio 8202M
Windows, All Outputs
 
Posts: 34 | Registered: May 22, 2014Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Display different variable options for -DEFAULT

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.