直接在操作系统中人工删除则没有任何问题?代码:
if RemoveDir('C:\Documents and Settings\Administrator\桌面\dde\') then
showMessage('OK')
else
ShowMessage('No'); if RemoveDir('C:\Documents and Settings\Administrator\桌面\dde') then
showMessage('OK')
else
ShowMessage('No');结果都是“NO”
if RemoveDir('C:\Documents and Settings\Administrator\桌面\dde\') then
showMessage('OK')
else
ShowMessage('No'); if RemoveDir('C:\Documents and Settings\Administrator\桌面\dde') then
showMessage('OK')
else
ShowMessage('No');结果都是“NO”
解决方案 »
- 00
- 怎样循环从数据库里读取记录
- 在chart控件中,在程序运行时怎么能实现对单个Series1用鼠标进行左右平移的拖动!在线等待!
- 如何使窗体和窗体内的组件按比例放大
- TSession控件的NetFileDir属性和PrivateDir属性
- 请问关于Treeview的高级编程问题!在线给分!进者有分!
- 怎样测试出一段字符串的长度
- 以满分求解
- --------------------如何求得几个点内的所有坐标?-----------------------
- 有没有类似我所提供的VB代码的CRC代码,请提供一下,谢谢
- 瞧一瞧,看一看,不要错过,小弟跪求一个问题,已经困扰几天了,请各位高手帮忙。
- 关于delphi调用存储过程
var
shfRecycleBinStruct: TSHFileOpStruct;
begin
FillChar(shfRecycleBinStruct,SizeOf(shfRecycleBinStruct),0);
with shfRecycleBinStruct do
begin
wFunc := FO_DELETE;
pFrom := PChar(Path);
fFlags := FOF_NOCONFIRMATION or FOF_SILENT;
end;
Result := SHFileOperation(shfRecycleBinStruct) = 0;
end;
with shfRecycleBinStruct do
begin
wFunc := FO_DELETE;
pFrom := PChar('C:\Documents and Settings\Administrator\桌面\dde');
fFlags := FOF_NOCONFIRMATION or FOF_SILENT;
end;
SHFileOperation(shfRecycleBinStruct) ;
ShowMessage(SysErrorMessage(GetLastError));---------------------------------------------------
错误提示:句柄无效