(Gast)
n/a Beiträge
|
AW: Sende String an comport
20. Jul 2014, 13:04
Warum nicht so?
Delphi-Quellcode:
procedure SENDSTRING (Buffer: String);
var BytesWritten: DWord;
begin
WriteFile(PortHandle,(Pchar(Buffer))^,Length(Buffer),BytesWritten,NIL);
END;
procedure TForm1.Button1Click(Sender: TObject);
var TextString : String;
begin
TextString := 'Hallo';
SendString (TextString+ #13);
end;
|
|
Zitat
|