如何判断一个目录是否存在,要用到哪个函数。

settingsun 2002-07-10 10:50:14
同上。
...全文
42 4 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
deldelmeme979 2002-07-10
  • 打赏
  • 举报
回复
if DirectoryExists('c:\windows') then
showmessage('There!')
else
...
deldelmeme979 2002-07-10
  • 打赏
  • 举报
回复
if DirectoryExists('c:\windows') then
showmessage('There!')
else
...
maafei 2002-07-10
  • 打赏
  • 举报
回复
function DirectoryExists(Name: string): Boolean;
Description

Call DirectoryExists to determine whether the directory specified by the Name parameter exists. If the directory exists, the function returns True. If the directory does not exist, the function returns False.

If a full path name is entered, DirectoryExists searches for the directory along the designated path. Otherwise, the Name parameter is interpreted as a relative path name from the current directory.
HHBB 2002-07-10
  • 打赏
  • 举报
回复
用DirectoryExists函数。

5,928

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧