Ryan,
I found this in my toolbox. I've not used it myself but it seems to be what you are looking for. It switches between two reports but I'm sure that you can adapt it to your needs.
-* File switch.fex
-* This fex creates 2 reports.
-* To save time recreating the hold file for the numbers report,
-* I've created an html file (switch.htm) where both reports are send to, but
-* only one is shown at a time. Through a javascript one can switch
-* between the two.
TABLE FILE CAR
SUM SALES
BY COUNTRY
ON TABLE HOLD AS SLS_CTY FORMAT HTMTABLE
END
TABLE FILE CAR
SUM SALES
BY CAR
ON TABLE HOLD AS SLS_CAR FORMAT HTMTABLE
END
-RUN
-HTMLFORM SWITCH
<html>
<head>
<title></title>
</head>
<style>
table {
font-family : verdana, arial, sans-serif;
font-size : 9 pt;
line-height : 12pt;
}
body {
font-family : verdana, arial, sans-serif;
font-size : 9 pt;
line-height : 12pt;
}
.table1 {
position : absolute;
}
.table2 {
position : absolute;
visibility : hidden;
}
.btnSwitch {
position : 500;
}
</style>
<script>
var activeReport = 1;
function showTable() {
eval('report' + activeReport + '.style.visibility = "hidden"');
activeReport = (activeReport == 1) ? 2 : 1;
eval('report' + activeReport + '.style.visibility = "visible"');
btnText = (activeReport == 1) ? 'To numbers' : 'To percentages';
document.all("btnSwitch").value = btnText;
}
</script>
</head>
<body>
<table><tr><td>
<input type=button class=btnSwitch onClick=showTable() value='To numbers' name='btnSwitch'> <br><br>
</td><td>
<span class=table1 id=report1>
!IBI.FIL.SLS_CTY;
</span>
<span class=table2 id=report2>
!IBI.FIL.SLS_CAR;
</span>
</td></tr></table>
</body>
</html>
Success,
Paul
Paul Burridge
Senior Consultant
34 years with Information Builders
WebFOCUS 8.2.5 Win10