随笔分类 -  文件处理

该文被密码保护。
posted @ 2016-07-25 14:07 ike_li 阅读(19) 评论(0) 推荐(0)
摘要:1.删除目录下所有的文件 void deleteAllFiles(const QString& fileDir) { QDir dir(fileDir); if(!dir.exists()) { return; } QFileInfoList fileInfofList=dir.entryInfoL 阅读全文
posted @ 2016-01-08 09:31 ike_li 阅读(427) 评论(0) 推荐(0)
摘要:一、使用总结 1.配置文件生成在exe目录下。 二、代码 阅读全文
posted @ 2015-11-18 15:54 ike_li 阅读(381) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2015-11-18 09:42 ike_li 阅读(26) 评论(0) 推荐(0)
摘要:/* @description:压缩文件操作 * @param filePath 要压缩的文件路径 * @param descDir 压缩文件保存的路径 d:\\aaa.zip */ public static void zipFiles(String ... 阅读全文
posted @ 2015-11-13 13:03 ike_li 阅读(266) 评论(0) 推荐(0)
摘要:#include "stdafx.h" #include #include #include #include #include using namespace std; LPWSTR StringToLPWSTR(string s) { const char * szString = s.c_str(); int dwLen = strlen(szString) +... 阅读全文
posted @ 2015-08-24 15:22 ike_li 阅读(1207) 评论(0) 推荐(0)
摘要:#include int i = 0;while (i < 20){ i++; WriteLog("d:\\log.txt","aaaa中国人民");}/utf-8格式//WriteLog("d:\\log.txt", "aaaa中国人民");void WriteLog(char* file_pa... 阅读全文
posted @ 2015-06-03 14:39 ike_li 阅读(3321) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2015-03-27 08:47 ike_li 阅读(2) 评论(0) 推荐(0)
摘要:使用方法: 创建压缩文件。可以指定压缩的文件保存在什么地方 //压缩文件路径和压缩文件名字,如:d:\\file.zip string zip_file_name = dest_zip_dir + "\\" + zip_name; TCHAR* t_zip_file_name = mystring. 阅读全文
posted @ 2015-03-20 17:03 ike_li 阅读(2609) 评论(0) 推荐(0)
摘要:1.下载http://www.zlib.net 下载,最新版本1.2.8 2.解压后,实际已提供了在vc下编译的工程,目录为:zlib-1.2.8\contrib\vstudio. 其中的zlibstat是编译为静态库,zlibvc是编译为动态库。 阅读全文
posted @ 2015-03-19 09:36 ike_li 阅读(2703) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2013-11-29 09:05 ike_li 阅读(18) 评论(0) 推荐(0)
摘要:MyFile.h MyFile.cpp CMyFile::MyDeleteDirectory("C:\\Messer_2.0changshi\\db"); CMyFile::MyCopyFile("C:\\Program Files\\MDB\\db","C:\\Messer_2.0changshi 阅读全文
posted @ 2013-04-19 15:08 ike_li 阅读(309) 评论(0) 推荐(0)
摘要:CopyFile只能复制一个文件,要想复制整个文件夹的所有文件,需要遍历文件夹里面的文件。 MyFile.h #pragma once #include <string> #include <Windows.h> #include <iostream> #include <stdio.h> #inc 阅读全文
posted @ 2013-02-04 15:40 ike_li 阅读(1210) 评论(0) 推荐(0)
摘要:using System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Runtime.InteropServices; using System.Text; na 阅读全文
posted @ 2009-07-23 14:15 ike_li 阅读(490) 评论(0) 推荐(0)
摘要:记录Errorlog //获得程序运行目录 using System.IO;using System.Diagnostics; string runExeDir = Path.GetDirectoryName(Process.GetCurrentProcess().MainModule.FileNa 阅读全文
posted @ 2009-02-18 15:33 ike_li
摘要:1.[代码][代码]2.通过bat方式上传[代码] 阅读全文
posted @ 2008-08-13 19:58 ike_li