zoukankan
html css js c++ java
MFC 中打开 文件,文件夹,以及删除文件,文件夹操作
/**************************************** 打开文件 **************************************/ void CFileSendClientDlg::OnOpenfile() { // TODO: Add your control notification handler code here POSITION pos= m_FileList.GetFirstSelectedItemPosition(); int _nSelect = m_FileList.GetNextSelectedItem(pos); if(_nSelect>=0){ ShellExecute(NULL,"Open",m_FileList.GetItemText(_nSelect,0),NULL,NULL,SW_SHOWNORMAL); }else { AfxMessageBox("请选择一个你要打开的文件"); } }
/**************************************** 打开文件目录 **************************************/ void CFileSendClientDlg::OnOpenpath() { ShellExecute(NULL,"Open","",NULL,NULL,SW_SHOWNORMAL); }
/**************************************** 删除文件 **************************************/ void CFileSendClientDlg::OnDelete() { // TODO: Add your control notification handler code here POSITION pos= m_FileList.GetFirstSelectedItemPosition(); int _nSelect = m_FileList.GetNextSelectedItem(pos); if(_nSelect>=0){ DeleteFile(m_FileList.GetItemText(_nSelect,0));// m_FileList.DeleteItem(_nSelect); }else { AfxMessageBox("请选择一个你要删除的文件"); } }
rmdir() DeleteDirectory(sTempDir) RemoveDirectory(sTempDir)
查看全文
相关阅读:
JS键盘码值表
JS入门笔记
CSS居中的方法总结
CSS布局模型思考
条件、循环、函数定义、字符串操作练习
Python输入输出练习,运算练习,turtle初步练习
如何理解Comparator接口中的升降序?
12个非常实用的JavaScript小技巧
JAVA泛型知识(一)
开窗函数简介
原文地址:https://www.cnblogs.com/javawebsoa/p/2458430.html
最新文章
【韦东山】嵌入式linux介绍
3月3日(5) Roman to Integer
3月3日(4) Binary Tree Inorder Traversal
3月3日(4) Remove Duplicates from Sorted List
3月3日(3) Binary Tree Preorder Traversal
3月3日(2) Search Insert Position
3月3日[Go_deep]Populating Next Right Pointers in Each Node
3月2日 Linked List Cycle
[ZZ+CH] Html5 canvas+js 时钟
2014年3月1日 Start && Unique Binary Search Trees
热门文章
重回cnblogs
webstorm 格式化代码及常用快捷键
通俗理解 React 高阶函数
ESLint
Mysql常用命令
Android 启动流程分析
adb shell top
Android休眠唤醒机制
Android休眠唤醒机制
JavaScript学习笔记之原型对象
Copyright © 2011-2022 走看看