You need to return a Vector and not an Array.
How to set values to a Combo Box using ssjs array variable?
-
11-10-2022 - |
سؤال
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.
المحلول
لا تنتمي إلى StackOverflow