One of those is that because I am using your toggle() function, my function key doesn't submit back to the RPG program so that it can change the text of the function key to reflect the inverse of the current subfile fold mode. Now, it is not necessarily a bad thing that my function key doesn't perform a submit back; however, the function key text does need to change accordingly. So, how can I detect the current subfile mode using JavaScript?
That's one... The other is that I can't seem to get my RPG code to be able to set the desired subfile fold mode upon rebuilding the screen. I've bound indicator fields to both the "expanded" and "return mode" properties and am interpreting them in RPG as follows. Is this not correct? (Note that the "return mode" property is bound to the COLLAPSED indicator.)
Code: Select all
if Screen.COLLAPSED = *off; // if grid is currently expanded
Screen.EXPANDED = *on; // indicate expanded mode is on
Screen.F8FoldText = 'F8 - Close'; // set button text for collapse
Screen.F8FoldIcon = 'up arrow'; // and set associated icon
else; // else
Screen.EXPANDED = *off; // indicate expanded mode is off
Screen.F8FoldText = 'F8 - Open'; // set button text for expand
Screen.F8FoldIcon = 'down arrow'; // and set associated icon
endif;