Hallo zusammen,
ich möchte in einer dll die Indy Komponente TFTP nutzen. So habe ich es mal probiert, haut aber leider nicht hin:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38:
| library TEST;
uses SysUtils, Classes, Dialogs, IdTrivialFTP in 'C:\Programme\Borland\Delphi7\Source\Indy\IdTrivialFTP.pas';
{$R *.res}
function GET_DATA(Server:String; FileName:String):Longint; stdcall; var TFTP: TIdTrivialFTP; FileStream: TFileStream; begin
try FileStream := TFileStream.Create('c:\test.txt', fmCreate); try TFTP.Create(<span style="color: red">[b]???[/b]</span>); TFTP.Host := '192.168.128.80'; TFTP.Get('test.txt', FileStream); finally TFTP.Free; end; finally FileStream.Free; end; result:=0; end;
exports GET_DATA;
begin end. |
...ich weiß nicht was ich bei TFTP.Create( ); für einen Owner übergeben kann nil und self geht nicht????
Kann mir jemand helfen????
Mario
Moderiert von
raziel: Delphi-Tags hinzugefügt.