本人刚接触delphi webservices ,现在有一问题procedure TForm1.Button1Click(Sender: TObject);
var
  ss : GeocodeSoap;
  sStr:string;
begin
  try
     ss:= GetGeocodeSoap(false,'');
     ss.GetGeocode('116.21444','28.22145');     //Edit1.Text := sStr;
  except
      on E:Exception do
      begin
        ShowMessage(e.Message);
      end;
  end;
end; 调用 GetGeocode 方法的时候报指针错误 'access violation at address 00cd23.write of address 00cd23'
 请高手赐教..
 下面是源码  // ************************************************************************ //
// The types declared in this file were generated from data read from the
// WSDL File described below:
// WSDL     : http://localhost/GEO/Ws/Geocode.asmx?wsdl
// Encoding : utf-8
// Version  : 1.0
// (2011-1-24 18:35:03 - 1.33.2.5)
// ************************************************************************ //unit Geocode;interfaceuses InvokeRegistry, SOAPHTTPClient, Types, XSBuiltIns;type  // ************************************************************************ //
  // The following types, referred to in the WSDL document are not being represented
  // in this file. They are either aliases[@] of other types represented or were referred
  // to but never[!] declared in the document. The types from the latter category
  // typically map to predefined/known XML or Borland types; however, they could also 
  // indicate incorrect WSDL documents that failed to declare or import a schema type.
  // ************************************************************************ //
  // !:string          - "http://www.w3.org/2001/XMLSchema"  // ************************************************************************ //
  // Namespace : http://tempuri.org/
  // soapAction: http://tempuri.org/GetGeocode
  // transport : http://schemas.xmlsoap.org/soap/http
  // binding   : GeocodeSoap
  // service   : Geocode
  // port      : GeocodeSoap
  // URL       : http://localhost/GEO/Ws/Geocode.asmx
  // ************************************************************************ //
  GeocodeSoap = interface(IInvokable)
  ['{C4F18C72-B3E9-5DF5-19AA-6813365712B2}']
    function  GetGeocode(const Longitude: WideString; const Latitude: WideString): WideString; stdcall;
  end;function GetGeocodeSoap(UseWSDL: Boolean=System.False; Addr: string=''; HTTPRIO: THTTPRIO = nil): GeocodeSoap;
implementationfunction GetGeocodeSoap(UseWSDL: Boolean; Addr: string; HTTPRIO: THTTPRIO): GeocodeSoap;
const
  defWSDL = 'http://localhost/GEO/Ws/Geocode.asmx?wsdl';
  defURL  = 'http://localhost/GEO/Ws/Geocode.asmx';
  defSvc  = 'Geocode';
  defPrt  = 'GeocodeSoap';
var
  RIO: THTTPRIO;
begin
  Result := nil;
  if (Addr = '') then
  begin
    if UseWSDL then
      Addr := defWSDL
    else
      Addr := defURL;
  end;
  if HTTPRIO = nil then
    RIO := THTTPRIO.Create(nil)
  else
    RIO := HTTPRIO;
  try
    Result := (RIO as GeocodeSoap);
    if UseWSDL then
    begin
      RIO.WSDLLocation := Addr;
      RIO.Service := defSvc;
      RIO.Port := defPrt;
    end else
      RIO.URL := Addr;
  finally
    if (Result = nil) and (HTTPRIO = nil) then
      RIO.Free;
  end;
end;
initialization
  InvRegistry.RegisterInterface(TypeInfo(GeocodeSoap), 'http://tempuri.org/', 'utf-8');
  InvRegistry.RegisterDefaultSOAPAction(TypeInfo(GeocodeSoap), 'http://tempuri.org/GetGeocode');
  InvRegistry.RegisterInvokeOptions(TypeInfo(GeocodeSoap), ioDocument);
end.