How to copy and paste a file with the clipboard from a compressed folder using VB.NET

How to copy and paste a file with the clipboard from a compressed folder using VB.NET

奈何桥上唱咆哮 发布于 2021-11-27 字数 476 浏览 943 回复 1 原文

How do I copy and paste a file with the clipboard from a compressed folder using VB.NET?

I want to paste a file from the clipboard that has been copied from a compress folder using VB.NET. By examining the clipboard, I see there is a FileGroupDescriptorW which seems to contain some information about the file. But how do I use the information to grab the file and paste it?

如果你对这篇文章有疑问,欢迎到本站 社区 发帖提问或使用手Q扫描下方二维码加群参与讨论,获取更多帮助。

扫码加入群聊

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

世态炎凉 2022-06-07 1 楼

The clipboard should contain data in the format of CF_HDROP. This can be converted to a file list by calling the DragQueryFile API.

Then it's just a list of fully-qualified filenames of whatever files were copied, and now you can operate on those files. A Visual Basic example is in How To Obtain Files Copied from Windows Explorer.