Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] HTML Composer - How to Reset Calendar Control.
Go
New
Search
Notify
Tools
Reply
  
[SOLVED] HTML Composer - How to Reset Calendar Control.
 Login/Join
 
Master
posted
I have a button control on my HTML page that resets my combobox and checkboxes with the following code:
//Begin function button2_onclick
function button2_onclick(ctrl) {
 document.getElementById('combobox1').selectedIndex=0;
 document.getElementById('checkbox1_0').checked=true;
 document.getElementById('checkbox3_0').checked=true;
 document.getElementById('checkbox4_0').checked=true;
 document.getElementById('checkbox5_0').checked=true;
 document.getElementById('checkbox6_0').checked=true;
}
//End function button2_onclick 


How can I now reset a calendar control I have on the same page?

I have 'Current/Start date' checked on the 'Properties and Settings' design form, so current date is indeed what I need to have the calendar control be reset to.

This message has been edited. Last edited by: <Kathryn Henning>,




Test: WebFOCUS 8.1.05M Prod: WebFOCUS 8.1.05M Server: Windows Server 2012/Tomcat Standalone Workstation: Windows 7/IE 11 Database: Oracle 12c/Netezza Output: AHTML/XLSX/HTML/PDF/JSCHART Tools: WFDS, Repository Content, BI Portal Designer, & ReportCaster

 
Posts: 780 | Registered: April 23, 2003Reply With QuoteReport This Post
Master
posted Hide Post
OK, I think I have a solution that seems to be working.

In function window_onload() I save off the calendar value:
initialdate = IbComposer_getCurrentSelection('calendar1');  

Then in the reset button function, I reset the calendar value:
//Begin function button1_onclick
function button1_onclick(ctrl) {
 document.getElementById('calendar1').value=initialdate;
}
//End function button1_onclick  
 
Posts: 780 | Registered: April 23, 2003Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] HTML Composer - How to Reset Calendar Control.

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.