3.2.0

Data Island Error for 2.0

anybody got a working example of an XML data island for the 2.0 software. I am getting an invalid procedure
call or argument error when I try to use it with the following code?

ASP Part:
rstData.Open strSQL, DataConn, adOpenForwardOnly, adLockReadOnly, adCmdText

Dim xml, xsl
Set xml = Server.CreateObject("MSXML2.DOMDocument")
Set xsl = Server.CreateObject("MSXML2.DOMDocument")

xml.async = False
xsl.async = False
rstData.Save xml, 1 'adPersistXML
xsl.load Server.MapPath("z.xsl")
strXML = xml.transformNode(xsl)
Set xsl = Nothing
Set xml = Nothing

<xml id="xmldata"><companies><%=strXML%></companies></xml>

Active Widgets Part:
<script language="javascript">
var table = new AW.XML.Table;
table.setXML(xmldata); //provide data URL
table.request(); // start asyncronous data retrieval
var columns = ["Contract/Task", "Task Title", "Project Controller", "Tier Level", "Tool", "Lead Div." , "CRN", "Prime CAN", "Start Date", "End Date", "Contract Type", "Negotiated Value", "Funded Value", "EAC Revenue", "EAC Fee", "EAC Fee %", "EAC Date", "Prior EAC Fee %", "Prior EAC Date" , "Issues/Comments"];

var obj = new AW.Grid.Extended;
obj.setId("myGrid");
obj.setControlSize(900, 450); // width, height of grid
obj.setColumnCount(20); //Number Of Columns to display
obj.setHeaderCount(1); // number of fixed header rows
obj.setHeaderText(columns);
obj.setFooterVisible(true); //Footer Info
obj.setFooterCount(1); //number of footer rows
obj.setFooterText(columns); // provide column labels
obj.setVirtualMode(true); //Virtual Mode
obj.setFixedLeft(1); // number of fixed columns on the left side
obj.setFixedRight(0); // number of fixed columns on the right side
obj.setSelectorVisible(true); //enable row selectors
obj.setSelectorText(function(i){return this.getRowPosition(i)});
obj.setSelectorWidth(0);
obj.setSelectionMode("single-row"); // set row selection
obj.setCellModel(table); // provide external model as a grid data source
document.write(obj); // write grid html to the page
</script>

error is on this line:

AW.HTTP.Request=AW.System.Model.subclass();AW.HTTP.Request.create=function(){var obj=this.prototype;obj.defineProperty("URL");obj.defineProperty("async",true);obj.defineProperty("requestMethod","GET");obj.defineProperty("requestData","");obj.defineProperty("responseText",function(){return this._http?this._http.responseText:""});obj.defineProperty("responseXML",function(){return this._http?this._http.responseXML:""});obj.defineProperty("username",null);obj.defineProperty("password",null);obj.setNamespace=function(name,value){this._namespaces+=" xmlns:"+name+"=\""+value+"\""};obj._namespaces="";obj.setParameter=function(name,value){this["_"+name+"Parameter"]=value;if(!this._parameters.match(name)){this._parameters+=" "+name}};obj._parameters="";obj.setRequestHeader=function(name,value){this["_"+name+"Header"]=value;if(!this._headers.match(name)){this._headers+=" "+name}};obj._headers="";obj.setRequestHeader("Content-Type","application/x-www-form-urlencoded");obj.getResponseHeader=function(name){return this._http?this._http.getResponseHeader(name):""};obj.request=function(){var self=this;this._ready=false;var i,name,value,data="",params=this._parameters.split(" ");for(i=1;i<params.length;i++){name=params[i];value=this["_"+name+"Parameter"];if(typeof value=="function"){value=value()}data+=name+"="+encodeURIComponent(value)+"&"}var URL=this._URL;if((this._requestMethod !="POST")&& data){URL+="?"+data;data=null}this._http=window.ActiveXObject?new ActiveXObject("MSXML2.XMLHTTP"):new XMLHttpRequest;this._http.open(this._requestMethod,URL,this._async,this._username,this._password);var headers=this._headers.split(" ");for(i=1;i<headers.length;i++){name=headers[i];value=this["_"+name+"Header"];if(typeof value=="function"){value=value()}this._http.setRequestHeader(name,value)}this._http.send(data);if(this._async){this.timeout(wait,200)}else{returnResult()}function wait(){if(self._http.readyState==4){self._ready=true;returnResult()}else{self.timeout(wait,200)}}function returnResult(){if(self._http.responseXML && self._http.responseXML.hasChildNodes()){self.response(self._http.responseXML)}else{self.response(self._http.responseText)}}};obj.response=function(result){if(this.$owner){this.$owner.refresh()}};obj.isReady=function(){return this._ready}};
Jim Shaffer
October 20,
Hey Alex,
Any Ideas??
Jim Shaffer
October 20,

This topic is archived.

See also:


Back to support forum