Cita:
Lo tengo en el escritorio como testSoap.html, en el mismo escritorio tambien está soapclient.js<head>
<script type="text/javascript" src="soapclient.js"></script>
<script type="text/javascript">
function User(id, username, password, expirationdate)
{
this.Id = id;
this.Username = username;
this.Password = password;
this.ExpirationDate = expirationdate;
}
function SendSamples_callBack(r)
{
if(r.constructor.toString().indexOf("function Error()") != -1)
alert("ERROR\r\n\r\n" + r.description + "\r\n\r\n[" + r.number + "]");
else
alert(r);
}
function SendSample5()
{
var ul = new Array();
ul[0] = new User(52342, "User1", "User1P@ss!", new Date());
ul[1] = new User(453, "User2", "User2P@ss!", new Date());
ul[2] = new User(5756, "User3", "User3P@ss!", new Date());
ul[3] = new User(5431, "User4", "User4P@ss!", new Date());
var pl = new SOAPClientParameters();
pl.add("userlist", ul);
SOAPClient.invoke(url, "SendSample5", pl, true, SendSamples_callBack);
}
</script>
</head>
<body>
<input type="button" onclick="SendSample5();" value="Send - 5">
</body>
<script type="text/javascript" src="soapclient.js"></script>
<script type="text/javascript">
function User(id, username, password, expirationdate)
{
this.Id = id;
this.Username = username;
this.Password = password;
this.ExpirationDate = expirationdate;
}
function SendSamples_callBack(r)
{
if(r.constructor.toString().indexOf("function Error()") != -1)
alert("ERROR\r\n\r\n" + r.description + "\r\n\r\n[" + r.number + "]");
else
alert(r);
}
function SendSample5()
{
var ul = new Array();
ul[0] = new User(52342, "User1", "User1P@ss!", new Date());
ul[1] = new User(453, "User2", "User2P@ss!", new Date());
ul[2] = new User(5756, "User3", "User3P@ss!", new Date());
ul[3] = new User(5431, "User4", "User4P@ss!", new Date());
var pl = new SOAPClientParameters();
pl.add("userlist", ul);
SOAPClient.invoke(url, "SendSample5", pl, true, SendSamples_callBack);
}
</script>
</head>
<body>
<input type="button" onclick="SendSample5();" value="Send - 5">
</body>
Gracias
Saludos