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



Mar 5, 2012, 2:11 PM
26 Posts

Getting scope variables in client side javascript (CSJS )

  • Category: Dojo and Client Side JavaScript
  • Platform: All
  • Release: 8.5.3
  • Role:
  • Tags:
  • Replies: 2
I set a viewScope variable with Server Side Javascript (SSJS).  Can I access that variable on the client side?   If so how?
 
Mar 5, 2012, 2:26 PM
298 Posts
executing SSJS in client side
Use alert("#{javascript:viewScope.myvar}"); Obviously you want to do something other than alert but you get the idea. Howard
Mar 5, 2012, 2:55 PM
56 Posts
Re: Getting scope variables in client side javascript (CSJS )
Hi,
 
be aware: The value will be computed on page load, that means if you change that value in the XPage, in your CSJS code, the initial value from the variable will be used, to update the value you have to refresh the page/ that element in which you use this variable.

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