摘要: 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppBuild.targets(298,5): warning MSB8004: Intermediate Directory does not end with a trailing slash. This build instance will add the slash as it is required to allow proper evaluation of the Intermediate Directory.1>C:\Program File 阅读全文
posted @ 2013-08-09 17:58 小小亮FLY 阅读(7094) 评论(0) 推荐(0) 编辑
摘要: 1 /*创建多级目录*/ 2 int CreateDir(const char *sPathName) 3 { 4 char DirName[256]={0}; 5 strcpy(DirName, sPathName); 6 int len = strlen(DirName); 7 for (int i=1; i<len; i++){ 8 if (DirName[i]!='/'){ 9 continue;10 }11 DirName[i] = 0;12 if (access(DirName, NULL)!=0 && mkdir(Di... 阅读全文
posted @ 2013-08-08 23:08 小小亮FLY 阅读(284) 评论(0) 推荐(0) 编辑
摘要: 1 #include "zlib.h" 2 #include "zip.h" 3 #include "unzip.h" 4 #include 5 #pragma comment(lib, "minizip.lib") 6 #pragma comment(lib, "zlib.lib") 7 8 9 #define dir_delimter '/' 10 #define MAX_FILENAME 512 11 #define READ_SIZE 8192 12 13 using s 阅读全文
posted @ 2013-08-08 16:34 小小亮FLY 阅读(2705) 评论(0) 推荐(0) 编辑
摘要: 网上好多人用JS+FLASH 实现复制到剪切板功能,貌似由于falsh版本的问题,有些写法已经不能用了。看到 http://www.iteye.com/ 网站提供代码复制到剪切板功能,就看了一下网站源码,把其复制功能摘录出来,给大家参考。也是使用FLASH实现的。看了下面的代码,怎么用应该不困难吧。 Click Right imge: 请注明来源:http://www.cnblogs.com/zhfuliang/p/3171000.html 阅读全文
posted @ 2013-07-04 09:55 小小亮FLY 阅读(387) 评论(0) 推荐(0) 编辑
摘要: 1)固定IP的设置@echo offset eth=无线网络连接set ip=61@echo 正在设置ip=192.168.240.%ip%netsh interface ip set address name=%eth% source=static addr=192.168.240.%ip% mask=255.255.255.0 gateway=192.168.240.1 gwmetric=0netsh interface ip set dns name=%eth% source=static addr=202.106.0.20 register=PRIMARYecho 设置完成!2 自动获 阅读全文
posted @ 2013-06-07 10:25 小小亮FLY 阅读(323) 评论(0) 推荐(0) 编辑
摘要: 1 try: 2 import hashlib 3 _new_md5 = hashlib.md5 4 except ImportError: 5 import md5 6 _new_md5 = md5.new 7 8 def _UnsignedFingerPrintImpl(str, encoding='utf-8'): 9 hex128 = _new_md5(str).hexdigest()10 int64 = long(hex128[:16], 16)11 return int6412 13 14 def UnsignedFingerPrint(str, e... 阅读全文
posted @ 2013-05-21 16:09 小小亮FLY 阅读(265) 评论(0) 推荐(0) 编辑
摘要: 1 /**读取文本中的内容,返回值需要自己手动释放,utf8,unicode格式的文本读取后需要自己转换*/ 2 char* ReadFileContent(char *filePath, int &contentLen) 3 { 4 FILE *fp = NULL; 5 fopen_s(&fp, filePath, "rb"); 6 assert(fp!=NULL); 7 if (fp == NULL) return NULL; 8 9 fseek(fp, 0, SEEK_END);10 int isize = ftell(fp);11 fseek(fp, 阅读全文
posted @ 2013-05-10 14:31 小小亮FLY 阅读(2041) 评论(0) 推荐(0) 编辑
摘要: 1 /**读取文本中的内容,返回值需要自己手动释放,utf8,unicode格式的文本读取后需要自己转换*/ 2 char* ReadFileContent(char *filePath, int &content_length) 3 { 4 FILE *fp = NULL; 5 fopen_s(&fp, filePath, "rb"); 6 assert(fp!=NULL); 7 if (fp == NULL) return NULL; 8 9 fseek(fp, 0, SEEK_END);10 int isize = ftell(fp);11 fseek 阅读全文
posted @ 2013-05-10 12:30 小小亮FLY 阅读(177) 评论(0) 推荐(0) 编辑
摘要: 安装:npm install -g node-inspector // -g 导入安装路径到环境变量如果安装失败可以尝试下方式(使用了代理进行下载安装):npm --registry "http://registry.npmjs.vitecho.com" install -g node-inspector调试:1 首先在cmd命令行中(默认是8080端口,如果需要修改端口就需要加上--web-port=端口号)node-inspector --web-port=8000 &2 运行js文件,需要加上 --debug-brk node --debug-brk 1.js 阅读全文
posted @ 2013-04-10 17:27 小小亮FLY 阅读(229) 评论(0) 推荐(0) 编辑
摘要: char* tchar_to_utf8(const TCHAR* str) {#ifdef _UNICODE int size = WideCharToMultiByte(CP_UTF8, 0, str, wcslen(str), NULL, 0, NULL, NULL); char* str8 = (char*) malloc(size+1); WideCharToMultiByte(CP_UTF8, 0, str, wcslen(str), str8, size, NULL, NULL); str8[size] = '\0'; return str8;#els... 阅读全文
posted @ 2012-11-02 15:08 小小亮FLY 阅读(855) 评论(0) 推荐(0) 编辑