Changes

Jump to: navigation, search

Pandora - Sample - Obtain System Variable

85 bytes added, 14:14, 21 February 2012
no edit summary
The following code will obtain the value from the [[System Variable]] called '''Registration Deadline'''
  var rs=variables_replacesession_getuser(false,"",40"firstname"); USERID=rs.getfieldbyname(1,"@me.userid@"); rs=variables_replace(false,"",40,USERID,"@system.Registration Deadline@");
var msg=rs.getfieldbyname(1,"msg");
alert("The Registration Deadline is " + msg);
==Notes==
* For system variables The first 2 lines obtain your user ID, in case it doesn't matter what object you process them against. In this case is relevant to the variables_replace search (ie: if the current variable is a user account is used.variable)* The '''variables_replace''' function returns the result in recordset in a field named '''msg'''
0
edits

Navigation menu