This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal



Apr 28, 2012, 9:14 AM
68 Posts
topic has been resolvedResolved

Changing table visibility using button.

  • Category: Server Side JavaScript
  • Platform: All
  • Release: 8.5.3
  • Role: Developer
  • Tags: Visibility
  • Replies: 2
Hi I'm looking for function to change visibility of table/object using button. I tried something like this:
 
var NowePytanie_Table:com.ibm.xsp.component.xp.XspTable = getComponent("NowePytanie_Table");
NowePytanie_Table.SetVisible(true);
 
but there is no such function as SetVisible (in normal Java it would work). 
Apr 30, 2012, 7:38 AM
53 Posts
Re: Changing table visibility using button.
I alwyas just use scoped variables - if you use a partial refresh you can use a viewscope, otherwise a sessionScope. Your table rendered properties then can just be viewScope.showthistable. If you want it do default to false you can set the viewScope in the beforepageload event of the xPage/custom control.
Apr 30, 2012, 8:16 AM
126 Posts
Re: Changing table visibility using button.
I think your looking for 
 
getComponent(<id>).setRendered(true / false);

This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal