DELPHI和VB使用的本来就不是一套类库
你可以使用 TFileListBox类
for i:=0 to FileListBox.Items.Count-1 do
FileListBox.Items[i]
你可以使用 TFileListBox类
for i:=0 to FileListBox.Items.Count-1 do
FileListBox.Items[i]
解决方案 »
- DELPHI多层次的显示和选择,帮忙想个法子
- DevExpress QuantumGrid 的问题,有没有 DBGridEh 中位列 的 Picklist 和 keyList 的功能,cxgrid 只有 items ,没有 keyitems
- 多了一个星,散分[4]
- 请问在Delphi7中怎样打印DBGRID中显示的数据,我用Dbgrid来显示ADOquery查询的内容
- 用Blob流的办法可以将大量的数据传送到数据库表的BLOB型字段中,SQL语句是如何实现的?
- 为什么RAVE报表老是有这个窗口弹出?进来看看.
- dbgrid超难问题求教!!!!!!!
- 请教delphi高手问题2
- 暴走啦!!!!
- delphi调用VC的DLL里的函数
- 十万火急!!!急啊!!300分求视频传输及捕获问题!先给23分回答后一定补上!!
- 发布一个药店管理系统源码
还是TDirectoryListBox合适吧?
//读取StrDir目录下的所有直接子目录到DirList中
var
SRec: TSearchRec;
retval: Integer;
begin
DirList.Clear;
retval:=FindFirst(strDir+'\*.*',faDirectory,sRec);
try
while retval=0 do
begin
if (SRec.Attr and faDirectory)<>0 then
if (Srec.Name='.')or(Srec.Name='..')then
begin
if IncludeSelf then
DirList.Add(Srec.Name)
end else
DirList.Add(Srec.Name);
retval:=FindNext(SRec);
end;
finally
FindClose(SRec);
end;
end;procedure FindFileUnder(strDir,ExtName:string;var FileList:TStringList);
//读取StrDir目录下的所有文件到FileList中
var
SRec: TSearchRec;
retval: Integer;
begin
FileList.Clear;
retval:=FindFirst(strDir+'\'+ExtName,faAnyFile,sRec);
try
while retval=0 do
begin
if (SRec.Attr and faDirectory)=0 then
FileList.Add(Srec.Name);
retval:=FindNext(SRec);
end;
finally
FindClose(SRec);
end;
end;
j:=i;
subfolders[j]去访问end
j是olevarint