如何实现下面的功能 
 用户向服务器固定地址192.168.1.103:7001/zhcxweb/getoutdata发送固定xml格式的请求报文
  服务器接收后解析验证合格后返回xml格式的结果报文。

解决方案 »

  1.   

    uses ComObj;
    var
      url:string;
      xmlHttp:Olevariant;
      responseText:Widestring;
      yourxmlstring:string;
    begin
      yourxmlstring:='<?xml verion=''1.0'' encoding=''utf-8''>................';
      url:='192.168.1.103:7001/zhcxweb/getoutdata';
      try
        xmlHttp:=CreateOleObject('Msxml2.XMLHTTP');
        xmlHttp.open('POST',url,false);
        xmlHttp.setRequestHeader('Content-Length', 20);
        xmlHttp.setRequestHeader('CONTENT-TYPE','application/x-www-form-urlencoded');
        xmlHttp.send(yourxmlstring);
        responseText:=xmlHttp.responseText;
        if xmlHttp.status='200' then
        begin
          //--
        end
        else
        begin
          //--
        end;
      except
        On E:Exception do
          //--
      end;
    end;
      

  2.   

    1楼使用ACTIVEX技术实现,无须控件呵呵