buenas estoy tratando de crear un Webservice en delphi 7 en la cual tengo una funcion pero me da este error:
[Error] wsKSMSImpl.pas(15): Unsatisfied forward or external declaration: 'TwsKSMS.enviarSMS'
mi codigo es este.
Código Delphi
[-]
unit wsKSMSImpl;
interface
uses SysUtils, Classes, IdHTTP,InvokeRegistry, Types, XSBuiltIns, wsKSMSIntf;
type
TwsKSMS = class(TInvokableClass, IwsKSMS)
public
function enviarSMS (url,usuario,clave,phone,mensaje : string) :string;stdcall;
end;
implementation
function enviarSMS (url,usuario,clave,phone,mensaje : string) :string;stdcall;
var
http: TIdHttp;
params: TStrings;
respuesta: string;
begin
http := TIdHTTP.Create(nil);
params := TStringList.Create;
begin
params.Add('usuario='+usuario);
params.Add('clave='+clave);
params.Add('telefonos='+phone);
params.Add('texto='+mensaje);
respuesta := http.Post(url, params);
end;
params.Free;
http.Free;
end;
exports
enviarSMS;
initialization
InvRegistry.RegisterInvokableClass(TwsKSMS);
end.