本例效果圖
代碼文件
unit Unit
interface
uses
Windows
Dialogs
type
TForm
Button
Memo
procedure Button
procedure FormCreate(Sender: TObject);
end;
var
Form
implementation
{$R *
procedure TForm
var
stream
b: Byte;
bs: string;
begin
{建立第一個流
stream
{把第一個流的十六進制編碼顯示在 Memo 中}
bs :=
for b in stream
Memo
{建立第二個流
stream
{把第二個流的十六進制編碼顯示在 Memo 中}
bs :=
for b in stream
Memo
stream
stream
end;
procedure TForm
begin
Memo
Memo
Memo
end;
end
窗體文件:
object Form
Left =
Top =
Caption =
ClientHeight =
ClientWidth =
Color = clBtnFace
Font
Font
Font
Font
Font
OldCreateOrder = False
OnCreate = FormCreate
PixelsPerInch =
TextHeight =
object Button
Left =
Top =
Width =
Height =
Caption =
TabOrder =
OnClick = Button
end
object Memo
Left =
Top =
Width =
Height =
Lines
TabOrder =
end
end
From:http://tw.wingwit.com/Article/program/Delphi/201311/24665.html