请问如何才可以实现移动文件夹,如将文件夹sh从C:\移到D:\

解决方案 »

  1.   

    用createdir在D:\新建sh目录,
    然后用findfirst和findnext查找C:\sh的所有文件,用copfile拷贝我不知道有没有新函数。
      

  2.   

    Performs a copy, move, rename, or delete operation on a file system object. WINSHELLAPI int WINAPI SHFileOperation(    LPSHFILEOPSTRUCT lpFileOp
       );
     ParameterslpFileOpPointer to an SHFILEOPSTRUCT structure that contains information the function needs to carry out the operation. Return ValuesReturns zero if successful or nonzero if an error occurs. See AlsoSHFILEOPSTRUCT
      

  3.   

    http://xuhao23.myetang.com/kj/file/
    简介:TFileOperation 构件封装了 Windows 95/Windows NT 4.0 Shell API 的 SHFileOperation 函数,能够很方便的复制、删除、搬移、更名文件