首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > .NET >

Delphi怎么编程实现文件复制、剪切?(不粘贴)

2012-03-09 
Delphi如何编程实现文件复制、剪切?(不粘贴)就是如同在操作系统中点中文件后右键弹出菜单,可以“复制”、“剪切

Delphi如何编程实现文件复制、剪切?(不粘贴)
就是如同在操作系统中点中文件后右键弹出菜单,可以“复制”、“剪切”文件到剪贴板?
网上看到的都是直接把一个文件复制到另一个目录下,我只想实现让用户“复制”、“剪切”,至于他最后到操作系统下是不是“粘贴”,不在程序里实现的那种效果?

[解决办法]
http://www.mscto.com/Delphi/27969205.html
参考

[解决办法]

Delphi(Pascal) code
BOOL   CopyFile(         LPCTSTR   lpExistingFileName, //   pointer   to   name   of   an   existing   file           LPCTSTR   lpNewFileName, //   pointer   to   filename   to   copy   to           BOOL   bFailIfExists   //   flag   for   operation   if   file   exists         );   HANDLE   CreateFile(         LPCTSTR   lpFileName, //   pointer   to   name   of   the   file           DWORD   dwDesiredAccess, //   access   (read-write)   mode           DWORD   dwShareMode, //   share   mode           LPSECURITY_ATTRIBUTES   lpSecurityAttributes, //   pointer   to   security   attributes           DWORD   dwCreationDistribution, //   how   to   create           DWORD   dwFlagsAndAttributes, //   file   attributes           HANDLE   hTemplateFile   //   handle   to   file   with   attributes   to   copy           ); 

热点排行