D
DanielLiu
Unregistered / Unconfirmed
GUEST, unregistred user!
始终不能正确接受到服务器端传回来的页面,代码如下
sURL:='http://eip.nhpower.com/SSO/SSOValidate2.dll';
sQuery:='username='+edit1.Text+'&password='+edit2.Text;
sURL:=sURL+'?'+sQuery;
sso:=TXMLHTTP30.Create(nil);
sso.open('post',sURL);
sso.setRequestHeader('content-length',inttostr(length(sQuery)));
sso.setRequestHeader('content-type','text/xml');
sso.send;
repeat
until sso.readyState=4;
edit3.Text:=sso.responseText;
其中sso.readyState始终为1,即表示正在接收,但是始终都不能为4(代表接收完毕)
若去掉repeat....until,则访问sso.responseText时出现"操作所需的数据不可用"!!
注: 同样的调用方法在ASP中通过!!!
sURL:='http://eip.nhpower.com/SSO/SSOValidate2.dll';
sQuery:='username='+edit1.Text+'&password='+edit2.Text;
sURL:=sURL+'?'+sQuery;
sso:=TXMLHTTP30.Create(nil);
sso.open('post',sURL);
sso.setRequestHeader('content-length',inttostr(length(sQuery)));
sso.setRequestHeader('content-type','text/xml');
sso.send;
repeat
until sso.readyState=4;
edit3.Text:=sso.responseText;
其中sso.readyState始终为1,即表示正在接收,但是始终都不能为4(代表接收完毕)
若去掉repeat....until,则访问sso.responseText时出现"操作所需的数据不可用"!!
注: 同样的调用方法在ASP中通过!!!