DavKli
Messages postés28Date d'inscriptionmardi 10 mars 2009StatutMembreDernière intervention31 octobre 2013
-
19 avril 2010 à 19:02
neo1667
Messages postés1Date d'inscriptionlundi 12 avril 2010StatutMembreDernière intervention11 octobre 2010
-
11 oct. 2010 à 15:18
Bonjour a tous,
voila mon souci, j'ai une appli que utilise une service externe WebService. Ca marche super sur mon poste mais sur un poste sans delphi je obtient une "Access violation at adress 00C25935. Write of adress 00C25935."
Voici le code source des 2 unites (le deuxieme est genere automatiquement a l'importation du webservice) :
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls, ExtCtrls, TypInfo;
type
TForm1 = class(TForm)
Button1: TButton;
ListBox1: TListBox;
procedure Button1Click(Sender: TObject);
private
public
{ Déclarations publiques }
end;
var
Form1: TForm1;
implementation
uses CurrencyConvertor;
{$R *.DFM}
procedure TForm1.Button1Click(Sender: TObject);
var
ws: CurrencyConvertorSoap;
Str1: string;
Str2: String;
int1: Integer;
begin
Button1.Enabled := False;
Ws := GetCurrencyConvertorSoap;
for Int1 := 0 to ord(High(Currency))-1 do
begin
Str1 := GetEnumName(TypeInfo(Currency), integer(Int1));
Str2 := Ws.ConversionRate(EUR, Currency(int1));
Str2 := Str1 + ' - ' + Str2;
Listbox1.Items.Add(Str2);
Application.ProcessMessages;
end;
Button1.Enabled := True;
end;
end.