3.2.0

setXML

Hi all

Does anyone have a working example of using table.setXML. Everytime I use it I just end up with [object] on the screen.

Many thanks
Frank
Franklin Cham
October 18,
I am having a problem also, but my error is Invalid procedure call or argument.

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 19,

This topic is archived.

See also:


Back to support forum