Then create an HTML form (named "z" as per my sample) in the same Content having this in the embedded java script tab
function window_onload() {
UpdateData();
var curval = '!IBI.AMP.CURYM;';
alert (curval);
}
Then run the procedure, you should have a popup displaying 201509.
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
September 30, 2015, 11:05 AM
Nicholas Spyrison
I have the popup displaying 201509.
commented out the alert.
It looks like it is trying to replicate the HTML file with the fex's frame. Do I need to specify a frame in the html filepath?
I also have curval in the Selected Value box it populates the first value rather than 201509.
Thanks for the continued support!
_____ WF 8.1.04 Win 7// Windows Server 2012 R2 SASS OLAP Cube
October 01, 2015, 11:10 AM
Barry Solomon
Hi Nicholas
I just saw your post and if you are using App Studio go to the settings panel or in Dev Studio go to the properties and setting window and look for "Selected Value" that will be the default and if you want a dynamic value set the Dynamic radio button and select a proc which will return the current date or the calculated date for the control to use. In App Studio you can set the current date with a check box.
Thanks Barry
WebFOCUS 8 Windows, All Outputs
October 01, 2015, 11:37 AM
Nicholas Spyrison
quote:
I just saw your post and if you are using App Studio go to the settings panel ... and look for "Selected Value" that will be the default and if you want a dynamic value set the Dynamic radio button and select a proc which will return the current date or the calculated date for the control to use.
Right I have all this, the date is stored in &CURYM, the "Selected Value" doesn't evaluate &CURYM how do I apply it?
quote:
In App Studio you can set the current date with a check box.
Where? still on the Settings tab. keep in mind that I need yyyymm rather than the date.
_____ WF 8.1.04 Win 7// Windows Server 2012 R2 SASS OLAP Cube
October 01, 2015, 12:28 PM
dhagen
You can do this completely in JS. In an onInitialUpdate function, add:
var d = new Date();
var n = d.getMonth();
var dt;
if (n < 9) {
dt = d.getFullYear().toString() + "/0" + (n+1).toString();
} else {
dt = d.getFullYear().toString() + "/" + (n+1).toString();
}
DM.DM.Date_Calendar_Month_YYYYMM.value = dt;
"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
October 01, 2015, 12:43 PM
Nicholas Spyrison
do so then how do I get the DM.DM.Date_Calendar_Month_YYYYMM.value dropdown conrol to default to dt?
I can't put dt in the "Selected Value" setting
_____ WF 8.1.04 Win 7// Windows Server 2012 R2 SASS OLAP Cube