Home Analytics Developing analytics applications
The community of Analytics developers are invited to follow and participate in the developer network.
OpenText technical experts collaborate with supported customers and partners in the Magellan product area.

what is the tag <VALUE-OF> really do how can I change the value between <VALUE-OF>x</VALUE-OF>

Hi there
Any one can help me about tag <!VALUE-OF> and what it is really do.
Thanks in advance ! (I changed <!!!!VALUE-OF> to <!VALUE-OF> and <!!!script> to <!script> can see it in post)
I have an array called “myArray” defined in Report Design “initialize” function
myArray = [];
Index = 0;
ArrayLength=0;
totalList= [];
In data onFetch function the value are assigned to the array and ArrayLength.
Now I am try to use them in one of the text item (HTML/list)
<!script>
function myFunc() {

    1. 1.   alert(<!VALUE-OF>ArrayLength</!VALUE-OF>);

2. 2. alert(<!VALUE-OF> ArrayLength </!VALUE-OF>);
3. 3. alert(<!VALUE-OF>totalArray[Index]</!VALUE-OF>);
4. 4 alert(<!VALUE-OF>totalArray[8]</!VALUE-OF>);
5.
but can't do

    1. i=8; alert(<!VALUE-OF>totalArray[i]</!VALUE-OF>);
    1. alert(<!VALUE-OF>totalList.pop()</!VALUE-OF>);
    1. alert(<!VALUE-OF>totalList.pop()</!VALUE-OF>);
    1. alert(<!VALUE-OF>totalList.pop()</!VALUE-OF>); got same data 3 times
  1. }
    <!/script>

The first four alert is working as I expected. What I want to do the get all the data in the array and use them in the function.

Something like
Var Myvar
For (Index =0; Index< ArrayLength; Index++)
{
Myvar = <!VALUE-OF>totalArray[Index]</!VALUE-OF>;
….
}
It complain Index in the totalArray[Index] in invalid.
Or
Var i;
For (i=0; i< ArrayLength); i++ ){ myVar = <!VALUE-OF>totalArray[i]</!VALUE-OF>;

Basically I can’t change the index for the array no mater I am using local variable or global variable,

<!VALUE-OF>Index</!VALUE-OF>++;
Index++;

Also if you look at the 4-6 it is always give (not ‘pop up’) the last item in the list, the size of the list never changed.

I am try to using reportContext.getGlobalVariable.. but can’t make it work. How can I change the data value between = <!VALUE-OF> </!VALUE-OF>;

Thanks and have nice day….

Comments

Sign In or Register to comment.