Focal Point
[SOLVED] in fex setting the html

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

October 27, 2009, 03:44 AM
Yangyang
[SOLVED] in fex setting the html
-HTMLFORM BEGIN
<_FORM>
<_SELECT>
<_select name=test1>
<_option value=1 selected>a<_/option>
<_option value=2>b<_/option>
<_option value=3>c<_/option>
-* others
!IBI.FIL.S001;
<_/SELECT>
<_/FORM>
-HTMLFORM END

how to setting the b is selected in fex file ?

or others?


Thanks
Yang

This message has been edited. Last edited by: Kerry,


WebFOCUS 7.6.8
WebFOCUS 7.6.10
BI
FLEX
.NET
October 27, 2009, 08:52 AM
john drews
You want "B" to be the default selected?

 
-HTMLFORM BEGIN
<_FORM> 
<_SELECT>
<_select name=test1>
<_option value=1>a<_/option>
<_option value=2 selected>b<_/option>
<_option value=3>c<_/option>
-* others
!IBI.FIL.S001;
<_/SELECT>
<_/FORM>
-HTMLFORM END

This message has been edited. Last edited by: john drews,


7.7.02 on Windows
October 27, 2009, 09:56 AM
Francis Mariani
Yang, if you put your code between
[code]
[/code]
tags, you would not need to have the "_" in your posting:

-HTMLFORM BEGIN
<FORM>
<SELECT name=test1>
<option value=1>a</option>
<option value=2 selected>b</option>
<option value=3>c</option>
-* others
!IBI.FIL.S001;
</SELECT>
</FORM>
-HTMLFORM END



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
October 28, 2009, 12:18 AM
Yangyang
thanks john drews
thanks Francis Mariani


is not default selected,

it's dynamic.

Thanks,
Yang


WebFOCUS 7.6.8
WebFOCUS 7.6.10
BI
FLEX
.NET
October 28, 2009, 05:11 AM
Tony A
The same way as you can reference a file within the HTMLFORM, you can reference an amper variable using
!IBI.AMP.variablename; (The semi colon is mandatory and is what folks normally forget).

So you could code -
<option value=1 !IBI.AMP.SelA;>a</option>
<option value=2 !IBI.AMP.SelB;>b</option>
<option value=3 !IBI.AMP.SelC;>c</option>
after setting one of &SelA, &SelB and &SelC to selected accordingly.

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 
October 28, 2009, 09:54 AM
Damien
Hope this will help you ?

SET PAGE=NOLEAD
SET LINES=99999
DEFINE FILE CAR 
S1/A8  = IF CAR EQ 'BMW' THEN 'selected' ELSE '' ; 
H1/A255='<select>';
L1/A255='<option value ="' | CAR |'"' | S1 |'>' | CAR  |'</option>' ; 
F1/A255= '</select>'; 
END 
TABLE FILE CAR 
"<H1"
PRINT L1
FOOTING
"<F1"
ON TABLE HOLD FORMAT DOC
END 
-RUN 
-HTMLFORM BEGIN
<form>
Select a value : !IBI.FIL.HOLD;
</form>
-HTMLFORM END 



Damien
WF 8202
DB : NETEZZA, MSSQL, DB2, ORACLE
Output : ALL
October 29, 2009, 04:52 AM
Yangyang
thanks Damien
thanks Tony A


i'm trying.

Thanks
Yang


WebFOCUS 7.6.8
WebFOCUS 7.6.10
BI
FLEX
.NET