查看《数据结构》啦,里面就有的,是用PASCAL写的。
解决方案 »
- 关于fastreport
- 求助~~~~~很急~~~关于子窗体的问题orz
- 按F1在任何时候都可以将QQ弹出来(QQ已经打开了)
- 关于中间件,三层,架构。。。
- 如何得到ie状态栏的文字?
- 都说dxdbgrid控件带打印功能,怎样直接打印在dxdbgrid中显示的数据?(在线)
- 点击window状态栏使应用程序最小化,是什么消息啊?
- 在WIN2000下编译运行通过,在WIN98上就不能运行,报错为什么?急急急。。。
- 使用Delphi的TMediaPlayer控件定制能播放实况视频流的媒体播放器!
- 当窗口创建时如何让光标定位到第一个控件上
- 我的软件出了新版本,希望大家能捧捧场
- 一个想不明白的问题,为何还有很多老兄在讨论Filter等方法?用select .. where ..不就搞定了吗?
procedure TForm1.Button1Click(Sender: TObject);type
PMyList = ^AList;
AList = record
I: Integer;
C: Char;
end;var MyList: TList;
ARecord: PMyList;
B: Byte;
Y: Word;
begin
MyList := TList.Create;
try
New(ARecord);
ARecord^.I := 100;
ARecord^.C := 'Z';
MyList.Add(ARecord); {Add integer 100 and character Z to list}
New(ARecord);
ARecord^.I := 200;
ARecord^.C := 'X';
MyList.Add(ARecord); {Add integer 200 and character X to list} { Now paint the items onto the paintbox}
Y := 10; {Variable used in TextOut function} for B := 0 to (MyList.Count - 1) do
begin
ARecord := MyList.Items[B];
Canvas.TextOut(10, Y, IntToStr(ARecord^.I)); {Display I}
Y := Y + 30; {Increment Y Value again}
Canvas.TextOut(10, Y, ARecord^.C); {Display C}
Y := Y + 30; {Increment Y Value}
end; { Cleanup: must free the list items as well as the list }
for B := 0 to (MyList.Count - 1) do
begin ARecord := MyList.Items[B];
Dispose(ARecord);
end;
finally
MyList.Free;
end;
end;