I am using the JavaScript version of @DbColumn to fetch data from a view in the same server. However it is not fetching all records only first 100 records are showing. The code :
====================================
uniqueValues = new Array();
var count;
function dbColumn(server,path,view,column,ObjProject)
{
xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
xmlDoc.async = false;
var pos=0;
currURL = (document.location.href).toLowerCase();
if (trim(server) == "")
{
pos = currURL.indexOf('://');
if (pos < 0 )
server = "http://www.xyz.com" //Put ur server name here
else
{
pos += 3;
pos = currURL.indexOf('/', pos);
server = currURL.substring(0, pos)
}
}
if( trim(path) == "" )
{
if( pos > 0 )
{
newPos = currURL.indexOf('.nsf',pos);
if (newPos > 0)
{
path = currURL.substring(pos+1,newPos+4)
}
}
}
if( !isNaN(column) )
column -= 1;
vurl = trim(server)+"/"+trim(path)+"/"+view+"?Readviewentries";
xmlDoc.load(vurl);
nodes = xmlDoc.documentElement.childNodes
temp = new Array(nodes.length);
var j = 0;
for (var i = 0; i < nodes.length; i++)
{
temp[j] = nodes.item(i).childNodes.item(column).text;
j++;
}
uniqueValues=getUniqueValues(temp)
results = new Array(parseInt(uniqueValues.length));
for (var i = 0; i < parseInt(uniqueValues.length); i++)
{
results[i] = uniqueValues[i];
}
writeInCombo(results,ObjProject);
}
function trim(str)
{
return str.replace(/^\s+/g, '').replace(/\s+$/g, '');
}
// To used for writing Project data into combo box
function writeInCombo(data,fldCombo)
{
fldCombo.length=0
fldCombo.length +=1
fldCombo[fldCombo.length-1].text = "Choose a Project for this Status Report"
for(iCount=0;iCount<data.length;iCount++)
{
fldCombo.length +=1
strText=data[iCount]
if (strText !=undefined && strText != null)
{
fldCombo[fldCombo.length-1].text = trim(strText)
}
}
}
====================================
- nodes length has 100 only.
Thanks,
Sanjay