I have a Tab application. Tab1 is an application that calls a form with a single, double select field, displaying dates. Tab2 is a form that displays a record based on the date(s) selection in Tab1.
So, I am trying to set a global variable to be passed to Tab2 on an Ajax change event.
Here is the code on the Ajax change event, {criteria} being the field on Tab1 :
$str = “{criteria}”;
$array=explode(’;’,$str) ;
sc_set_global($array) ;
When I run the application, I can select a date, using the right arrow to move it from left column to right column. When I select a 2nd date, instead of adding the 2nd date to the right column, the first date is removed from the right column (like I’ve reloaded the page). If I remove the sc_set_global($array) line, the date selection works as intended, but of course that doesn’t do me any good as far as setting my criteria to be passed to Tab2. So, am I not allowed to set a global variable in an Ajax event?