[SOLVED]DS HTML Composter: How to add a Defer button to an existing html launch page?
I can't figure out how to add a Run Defer button to an existing html launch page. Any ideas?
(Mod: changed the word "can" to "can't"!!!)
Thanks,This message has been edited. Last edited by: Francis Mariani,
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 21, 2011, 04:24 PM
njsden
Create a brand new page, copy/paste the "behind the scenes" code generated by HTMl composer for the 'Run Defer' control into the old page and adjust parameters accordingly ...
Other than style (which includes Z-INDEX), I think requests_list, name and tabIndex are to be adjusted.
requests_list="1" in my sample page has this code further ahead in the .htm file:
<requestid id="1"></requestid>
There's nothing really there but it's better to leave it. If I delete the Run Defer button, the requestId tag also gets removed.
The weird part is that I could not find anything else in the page that would hint WF to know that OnExecute() should start a "Run Defer" action as the "Run Schedule" button does exactly the same ... unless the javascript API is "smart" enough to make decisions based on the control name (form1Defer vs. form1Schedule in this case).
I don't think this helps much but it's the best I could see.
Neftali, this might help me. I was afraid I may miss something if I hacked the code because of what might be lurking past the HTML input tag...
I'll give it a try.
Thanks,
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 21, 2011, 05:02 PM
njsden
I know what you mean. I'm usually "brave" when creating pages from scratch (and that's a lot to say) but editing existing ones is a whole different beast to tame!
Just don't forget to make at least 3 backup copies before ... you know This message has been edited. Last edited by: njsden,
I would have thought that all you need to run deferred is to have a object called IBIMR_defer, and set it to "defer".
But I don't use composter.
Waz...
Prod:
WebFOCUS 7.6.10/8.1.04
Upgrade:
WebFOCUS 8.2.07
OS:
Linux
Outputs:
HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!
October 24, 2011, 09:24 AM
Francis Mariani
quote:
IBIMR_defer
I'll be trying this now, as this is what we used to do back in the days of beautiful, hand-tooled code.
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 24, 2011, 10:39 AM
Francis Mariani
OK, I've figured this out. As per the old fashioned technique, I created a hidden text field called IBIMR_defer. Then I added a new button that sets the text field to "defer", submits the report fex and sets the text field back to blank. I had to also "bind" a report parameter called IBIMR_defer.
Now I neeed to replicate this in 9 other HTML files.
I isolated the code and this is what I have to copy:
JS:
//Begin function button13_onclick
function button13_onclick(ctrl) {
// TODO: Add your event handler code here
document.getElementById('IBIMR_defer').value = 'defer';
OnExecute(ctrl)
document.getElementById('IBIMR_defer').value = '';
}
//End function button13_onclick
The unfortunate part of looking at the code is that the "bound" report parameters generate an overdose of code that I'm afraid to paste into the HTML file (for instance, why are there 'slider_range_from' and 'slider_range_to' tags for a hidden text field?):
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 24, 2011, 05:21 PM
Francis Mariani
I decided to be a good boy and follow orders by doing it using the GUI - I only copy-pasted the JavaScript lines.
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 24, 2011, 05:29 PM
Waz
Oh how the great have fallen.
Waz...
Prod:
WebFOCUS 7.6.10/8.1.04
Upgrade:
WebFOCUS 8.2.07
OS:
Linux
Outputs:
HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!
October 25, 2011, 12:47 PM
David Glick
There is no need for any manual coding or copy/pasting. If you right-click the form, there is an option on the context menu to Add a Defer button.
If you don't have a form, you create a button, and then right-click it to invoke the Hyperlink Properties and set a hyperlink to use an external procedure (your report), and then from the Target column, select Defer.
That's it...
David Glick Director WebFOCUS App Studio and WebFOCUS Developer Studio WebFOCUS Division Information Builders, Inc. Direct (917) 339-5560 Voice Mail (212) 736-6250 x3560 Fax (212) 947-5168 Email david_glick@ibi.com
October 25, 2011, 04:41 PM
Waz
quote:
right-click the form
Who'd a thunk it ?
Waz...
Prod:
WebFOCUS 7.6.10/8.1.04
Upgrade:
WebFOCUS 8.2.07
OS:
Linux
Outputs:
HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!
October 25, 2011, 06:50 PM
njsden
quote:
Who'd a thunk it ?
Agreed! The funny part is that when playing with this I right-clicked the report to "Refresh parameters" and even the "Submit" button to get to "Hyperlink properties" to see if an option to include the "Run Defer" button was offered. It just never occurred to me to right-click the actual form ...
quote:
be a good boy and follow orders by doing it using the GUI
Perhaps I should do as Francis ... who knows, I may start finding pleasant surprises within the realm of the GUI
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
April 04, 2012, 02:47 PM
Kafka
Hi Francis, This is Lee Martin. I am trying to do the same thing being talked about here and was only partially successful. I am able to copy a self_service htm file into MRE, add the deferred button and it submits a report deferred. But I'm unable yet to pass the parms collected from the htm page. It just calls the .fex and "autoprompts". What am I missing as far as passing the parms to the .fex using the Deferred button? Any help would be much appreciated. Thanks.