获取在Windows 资源管理器中执行COPY/PASTE的文件列表信息

      在文件传输模块开发过程中,要实现这样的一个功能:在资源管理器中对选中的文件或者文件夹CTRL+C,在聊天窗口中按下CTRL+V,获取用户选择的文件或文件夹发送给对端用户。这其中存在一个问题:如何从剪切板数据中获取用户选择了哪些文件或文件夹呢?经研究和测试,用如下的代码可以获取到文件列表信息:

    if( ::OpenClipboard( NULL ) ) // 打开剪切板
     {       
	HDROP hDrop = HDROP( ::GetClipboardData( CF_HDROP ) ); // 获取剪切板中复制的文件列表相关句柄
        if( hDrop != NULL ) 
		{
			char szFilePathName[MAX_PATH+1] = {0};	
			UINT nNumOfFiles = DragQueryFile( hDrop, 0xFFFFFFFF, NULL, 0 ); // 得到文件个数
			
			// 考虑到用户可能同时选中了多个对象(可能既包含文件也包含文件夹),所以要循环处理
			for ( UINT nIndex=0 ; nIndex<nNumOfFiles; ++nIndex )	
			{
				memset( szFilePathName, 0, MAX_PATH+1 );
				DragQueryFile( hDrop, nIndex, szFilePathName, MAX_PATH );  // 得到文件名
			}
		}

        ::CloseClipboard(); // 关闭剪切板
      } 

RStudio安装避坑指南:识别非官方版本与Win10兼容配置 RStudio是R语言最主流的集成开发环境(IDE),其版本号基于构建时间戳(如2023.09),而非日历年份,所谓‘RStudio 2026’纯属误导性命名,多源于搜索引擎劫持、镜像站误标或R与RStudio版本混淆。理解语义化版本逻辑与IDE构建机制,是保障软件可信安装的技术前提;结合Windows 10系统特性(如MSI兼容性、区域设置、UAC权限、字体渲染链路),可系统性规避安装失败、中文乱码、静默挖矿等高危风险。本文聚焦RStudio Desktop在Win10平台的官方安装验证、安全下载溯源、静 阅读详情

相关推荐

Aitiy全局效率工具:鼠标手势、OCR与快捷操作一体化配置指南

在计算机操作中,提升效率往往依赖于对基础交互方式的优化。鼠标手势作为一种直观的输入方式,通过预设轨迹代替复杂点击,能显著缩短操作路径。光学字符识别(OCR)技术则解决了从非标准文本源(如图片、视频帧)中提取信息的难题,将视觉内容转化为可编辑的文本数据。这些技术的核心价值在于减少上下文切换,实现操作流的无缝串联,从而在文档处理、信息收集、多任务管理等应用场景中大幅提升生产力。本文以Aitiy工具为例,深入探讨如何通过配置鼠标手势与OCR套件,构建一体化的快捷操作体系,实现“选中即操作”的流畅体验。

weixin_30920513的博客 326

获取计算机当前的使用信息(支持所有windows系列系统)

获取计算机当前的使用信息(支持所有windows系列系统),可以把收集到的信息保存成txt、html等格式,方便使用。

vc使用全局鼠标钩子实现右键双击粘贴操作.zip

vc使用全局鼠标钩子实现右键双击粘贴操作.zip visual c++ 全局hook 鼠标钩子实现右键双击=粘贴操作

魔兽RPG老地图逆向工程:解密三国列传3.0武将招募限制(附JASS实战)

本文详细解析了《三国列传3.0》魔兽RPG地图的武将招募限制机制,通过逆向工程和JASS脚本修改技术,突破SLK加密防线并解密游戏逻辑。文章提供了从工具准备到代码修改的完整实战指南,帮助玩家解除武将数量限制,重温经典游戏的乐趣。

i1j2k的博客 374

RandLA-Net 调通代码1:Windows 11 + Tensorflow 2.4 + S3DIS数据集【踩坑+填坑】

TF不上进啊,学学pytorch

累了就要打游戏 2485

OFDM调制matlab仿真详细代码

MATLAB仿真代码 % ================================================== % 作者: 肆拾伍 % 时间:11/30 2019 % 版本:V3 % =================OFDM仿真参数说明:================ % % 子载波数 carrier_count ---200 % 总符号数 symbol_count ...

肆拾伍的博客 3万+

光线追踪渲染实战:蒙特卡洛路径追踪及其c++实现

光线追踪超越了传统的图形流水线,是一种现代的渲染。光线追踪是一种基于物理的渲染方法,通过模拟光在介质中的真实表现来输出足以逼近现实的图像。光线从光源出发,经过各种反射折射,进入摄像机。通过渲染方程描述一点的颜色,并且通过蒙特卡洛方法求解渲染方程来获取最终的像素颜色。

AKGWSB 's blog 1万+

从零拆解快手Web端__NS_hxfalcon:JS逆向签名参数定位与复现

在JS逆向与前端反爬攻防中,签名参数总是绕不开的核心环节。无论是接口加密还是请求签名,其本质都是通过在客户端收集环境信息、时间戳与业务参数,经特定算法计算后生成用于服务端校验的动态令牌。理解这类参数的生成原理,不仅能提升逆向分析效率,也能帮助前端开发者更好地设计自身接口防护方案。在实际工程中,面对经Webpack打包且高度混淆的代码,直接全局搜索参数名往往难以奏效,需要结合请求抓包、调用栈跟踪、环境适配等方法逐步定位。此类签名参数广泛存在于现代Web应用的GraphQL或REST接口中,是接口数据安全的重要

weixin_29474431的博客 340

DDR5 输入时钟抖动规范全解析!技术宅必看

简单说,时钟抖动就是时钟信号边沿的“颤抖”——信号本来应该在某个固定时间跳变,但实际时刻可能会前后波动。这种波动可能是随机的,也可能是确定性的。随机抖动(Random Jitter, Rj):符合高斯分布,像是你家猫咪不经意的晃动。确定性抖动(Deterministic Jitter, Dj):受限于特定周期或模式,像是邻居装修时的规律敲击声。⚠️ 注意,如果时钟抖动超出规格,DDR5可能无法正确接收或发送数据,内存错误、系统崩溃可就跟着来了!

weixin_43199439的博客 401

中国各城市土地利用类型(城市功能)数据集(shp)

中国各城市土地利用类型(城市功能)数据集时间:2018年全国范围的城市用地类型数据(居住/商业/交通用地等共计11类)分类:居住用地、商业用地、工业用地、医疗设施用地、体育文化设施用地、交通场站用地、绿地等用地类型含城市编码、一级分类5个、二级分类11个1、上海市。

你好,我是小张同学! 1341

《Zephyr OS 入门与实战》第1章:Zephyr OS 架构与物联网定位

【代码】《Zephyr OS 入门与实战》第1章:Zephyr OS 架构与物联网定位。

2301_79143213的博客 1278

锂电池充电器电路设计 里面有电路

锂电池充电器电路设计 里面有电路 3.7V升压到5V电路设计。

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

蓝牙模块HM-10手册

蓝牙模块HM-10手册,该手册对蓝牙模块HM-10进行了详细的介绍和使用方法以及一些AT指令。

上一篇: C++ debug下情况良好、release下频繁奔溃问题的跟踪与解析
下一篇: 工作中多讨论多交流的益处
dvlinker
dvlinker 领域专家: C/C++技术领域 领域专家: C/C++技术领域
博客等级 码龄19年 13万+粉丝 1015原创
评论 1
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

dvlinker

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值