Focal Point
How to default "Select all" in autoprompt?

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/2881031912

March 20, 2007, 10:43 AM
<JJI>
How to default "Select all" in autoprompt?
How can I default the "Select All" in the WF auto prompt param screen.

I can default the "No selection" for a dynamic filled dropdown list by setting the default to 'FOC_NONE'.
Example:
-DEFAULT &Dept = 'FOC_NONE' ; 

.
.
.
WHERE DEPARTMENT EQ &Dept.  (OR(FIND DEPARTMENT IN VW_REPORT_PARAM_PROMPT)).Department.;  


Now I want to do the same for a non dynamic list:
Example:
 WHERE Type_Mouvement  EQ &Type.(OR(<In Service,1>,<Out Service,2>,<In Serviceand Out Service,3>)).In/Out Service. ; 


Now when running the code the first selection option is "Select All" which is normal, but how kan I default this option?
-DEFAULT &Type= '1 OR 2 OR 3' ; 
will default all 3 options under the "Select All" instead of the "Select All" itself.

Any idea's?

I know you can do all this by coding the html myself but that is not allowed here. (not yet any way Frowner )
March 20, 2007, 12:35 PM
Alan B
-DEFAULT &Type='FOC_ALL';

should do the trick.


Alan.
WF 7.705/8.007
March 20, 2007, 01:15 PM
Francis Mariani
quote:
FOC_ALL


Never seen "FOC_ALL" before.

Incidentally, "FOC_NONE" is not documented in the 5.3.2 manual, "FOCNONE" is mentioned once in the 5.3 New Features document and once in the 5.3 Developing Applications document.

Hopefully this is better documented in newer versions.


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
March 20, 2007, 01:27 PM
Alan B
Francis

I dug into the js a little bit, but then realised that you can glean this from the view source when in autoprompt. Unlike FOC_NONE it does get translated to every value in the select through the js.

Though you're right, it should be documented.


Alan.
WF 7.705/8.007
March 20, 2007, 02:19 PM
FrankDutch
Undocumented features is that the same as a bug?

But I will put this in my folder "nice to know"

thanks Alan!




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

March 20, 2007, 03:52 PM
TexasStingray
quote:
Undocumented features is that the same as a bug?


No

Undocumented features are sometimes things that are in the process of being developed but not fully cooked or supported yet.

When I wrote code I loved to add secret undocumented features and see if anyone ever found then accidently. At a later time I would document them.

FYI




Scott

I knew that Texas...just joking.




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

"FOC_ALL" it is. Thank you so much Alan.

Francis, I'm afraid it's not better documented in the newer versions. Otherwise I would have found it .... I think. Big Grin

Thanks to all.
FOC_ALL this does not work....


TABLE FILE CAR
SUM SALES BY COUNTRY
SUM SALES BY COUNTRY BY CAR
PRINT SALES RCOST DCOST COMPUTE PROFIT/D6=RCOST - DCOST;
BY COUNTRY BY CAR BY BODYTYPE
ON COUNTRY SUBTOTAL 
WHERE  COUNTRY EQ 'FOC_ALL';
ON TABLE SET HTMLCSS ON
ON TABLE PCHOLD FORMAT HTML
END  


What do I do wrong?

Frank




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

Frank,

I believe that the FOC_ALL is meant to be used in the DEFAULT prior to an autoprompt. Then the FOC_ALL is expanded into all the values from the combo box as per Alan's post above.

Correct me if I am wrong.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
Tony, you are correct.

The FOC_ALL is active only within the js, and does not work directly within the FOCUS code; in this way it is different to FOC_NONE, which has direct meaning in the TABLE parser.


Alan.
WF 7.705/8.007
Alan,

Thanks for the confirmation that I am not going mad after all Wink

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10