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] Clear Checkbox Control
Go
New
Search
Notify
Tools
Reply
  
[SOLVED] Clear Checkbox Control
 Login/Join
 
Member
posted
I have an html page, created using HTML canvas, that contains text areas, check boxes, and a submit button. I have one on click task associated with the submit button that runs a fex and refreshes the texts areas and check boxes. I cannot figure out how to get the refresh action to work for the check boxes when they follow a request to run fex file in the action list. The text areas refresh fine, and the check boxes will refresh if I remove the request to run the fex file. Is there anything I can do to make this work?

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


WebFOCUS 8.2.06, Windows
 
Posts: 19 | Registered: July 18, 2019Reply With QuoteReport This Post
Virtuoso
posted Hide Post
When you say "refresh the check boxes", what action/result do you expect to have ?


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
 
Posts: 2365 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Reply With QuoteReport This Post
Member
posted Hide Post
Empty check boxes.


WebFOCUS 8.2.06, Windows
 
Posts: 19 | Registered: July 18, 2019Reply With QuoteReport This Post
Master
posted Hide Post
In the onclick event add in the following:
  
document.querySelectorAll('input[type="checkbox"]').forEach(el=>el.checked = false)


Hallway

 
Prod: 8202M1
Test: 8202M4
Repository:
 
OS:
 
Outputs:
 
 
 
 
 
Posts: 608 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015Reply With QuoteReport This Post
Member
posted Hide Post
The onclick event works to clear the checkboxes; but, it clears them before the parameters are passed to the procedure. I can can make it work with two buttons, but thought for sure there would be a way to order tasks so that the same button could first pass the parameters and run the procedure, and then clear values from the check boxes. Setting the Refresh action on the text area input controls in the Tasks & Animations utility does this. I've explored the Properties for my submit button, but have not yet been able to figure out how to make it work.


WebFOCUS 8.2.06, Windows
 
Posts: 19 | Registered: July 18, 2019Reply With QuoteReport This Post
Guru
posted Hide Post
quote:
document.querySelectorAll('input[type="checkbox"]').forEach(el=>el.checked = false)

You can create a new function to clearCheckBoxes with this one line and add it to your task as last action. Or you could do it all as one JS function by running the report using IBcomposer_triggerExecute followed by this clearAll jquery script.


-********************
Sandbox: 8206.10
Dev: 8201M
Prod:8009
-********************
 
Posts: 283 | Location: Houston,TX | Registered: June 11, 2004Reply With QuoteReport This Post
Member
posted Hide Post
Wow. I really thought that I had tried that. I guess not. Thank you!


WebFOCUS 8.2.06, Windows
 
Posts: 19 | Registered: July 18, 2019Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] Clear Checkbox Control

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