Hello Murthy,
This is a known problem in showModalDialog. See following links.
If you really want to return an array and access it I suggest you clone it as shown below or use a string as return value.
function cloneArray(ary) {
var i;
var newAry = [];
for (i = 0; i < ary.length; i++){
if (Object.prototype.toString.call(ary[i]) == '[object Array]') {
newAry.push(cloneArray(ary[i]));
} else {
newAry.push(ary[i]);
}
}
return newAry;
}
function fnOpen() {
var sFeatures = fnSetValues();
window.returnValue = undefined;
var retVal = window.showModalDialog("http://localhost:8080/myapp/dialog.htm", "", sFeatures)
alert(cloneArray(retVal));
}
Regards,