Question

I get values from Db using jdbc and store them in a String Array object. I have a combobox in an xpage and computed its values using ssjs.

The java class has a function,

String[] array = new String[20];
    public String[] getName(){
return array;
}

The ssjs code is,

    var v = new com.vijay.Test1();
var ar = new Array();

for(i=0;i<@count(ar);i++)
ar[i]= "["+v.getName[i]+"]";

return ar;

But when previewed, the combobox has no values.

Was it helpful?

Solution

You need to return a Vector and not an Array.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top