- 博客(18)
- 收藏
- 关注
转载 下载网页
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <io.h> #include "curl.h"#pragma comment(lib,"libcurl_imp.lib")#define POSTURL "http://www.hao123.com...
2015-10-19 13:15:00
125
转载 ubuntu上安装mysql
1.sudo apt-get install mysql-server2.sudoapt-get isntall mysql-client3. sudo apt-get install libmysqlclient-dev检查安装是否成功sudo netstat -tap | grep mysql通过上述命令检查之后,如果看到有mysql 的socket...
2015-09-23 16:39:00
111
转载 linux下Qt Creator使用curses
获取curses库文件终端输入sudo apt-get install libncurses5-dev包含头文件#include <curses.h>在.pro文件中加入lib库LIBS+=-L /usr/lib -lcurses转载于:https://www.cnblogs.com/cqhstyle/p/4831911.html...
2015-09-23 12:49:00
219
转载 资源和限制
#include <sys/types.h>#include <sys/resource.h>#include <sys/time.h>#include <stdio.h>#include <unistd.h>#include <stdlib.h>#include <math....
2015-09-23 00:00:00
132
转载 获取主机和用户信息
#include <sys/types.h>#include <sys/utsname.h>#include <pwd.h>#include <stdio.h>#include <unistd.h>#include <stdlib.h>int main(int argc,char * a...
2015-09-22 23:32:00
107
转载 目录扫描
#include <unistd.h>#include <stdlib.h>#include <stdio.h>#include <dirent.h>#include <string.h>#include <sys/stat.h>void printdir(char *dir,int dept...
2015-09-22 18:11:00
122
转载 文件复制
#include <unistd.h>#include <stdlib.h>#include <sys/stat.h>#include <fcntl.h>int main(){ char c; int in,out; in=open("file.in",O_RDONLY); out=...
2015-09-22 16:07:00
84
转载 socket建立简单顶C/S程序
服务器端#include <stdio.h>#include <arpa/inet.h>#include <sys/socket.h>#include <cstring>#include <sys/types.h>#include <stdlib.h>#include &...
2015-09-07 21:05:00
80
转载 简化qt程序发布
具体步骤:1、先动态编译链接,生成exe文件(release方式)2、找到依赖的dll文件这里,我们可以用ProcessExplore来获取所依赖的dll文件下载:打开procexp.exe,通过菜单View==》LowerPaneView==》DLLs勾选,显示dll窗口这里,我们以test.exe为例,在Qt环境下,将exe运行起来,在Proc...
2015-09-02 03:05:00
110
转载 Qt登录对话框
QString c_user,c_password; c_user=CLoginUi->m_user->text().trimmed(); c_password=CLoginUi->m_password->text().trimmed(); if(c_user!=NULL&&c_password!=NULL) { ...
2015-09-02 02:59:00
80
转载 Qt数据库连接
#ifndef CONNECTION#define CONNECTION#endif // CONNECTION#include <QtSql/QtSql>#include <QtSql/QSqlDatabase>#include <QtSql/QSqlQuery>#include <QMessageBox>static bool cr...
2015-09-02 02:58:00
85
转载 MFC分隔字符串的四种方法
vector<CString> SplitCString(CString strSource, CString ch){vector <CString> vecString;int iPos = 0;CString strTmp;strTmp = strSource.Tokenize(ch,iPos);while(strTmp.Trim()...
2015-09-02 02:54:00
350
转载 二进制数据库的存取
一:将数据以二进制的形式存储到数据库这里,我们以float一维数组的形式存储多个点的坐标:思路:先将float数组转化为char数组,然后将其转化为safeArray并存储到BLOB数据中,然后存储在数据库中的image字段中。1:将float数组转化为char数组:函数输入:flaot一维数组 数组中包含个数n输出:char一维数组具体代码:ch...
2015-09-02 02:51:00
213
转载 vs2010遇到转换到 COFF 期间失败: 文件无效或损坏解决方法
VS2010在经历一些更新后,建立Win32 Console Project时会出“error LNK1123” 错误,解决方案为将 项目|项目属性|配置属性|清单工具|输入和输出|嵌入清单 “是”改为“否”即可,但是没新建一个项目都要这样设置一次。第一步:与上相同。第二步:将 项目|项目属性|配置属性|连接器|清单文件|嵌入清单 “是”改为“否”。第三步:一般计算机经过上两步设置就能解...
2015-09-02 02:48:00
229
转载 班级通讯录管理系统
#include <iostream>#include <fstream>#include <string.h>using namespace std; struct student{ char s_no[20]; char s_name[20]; char s_sex[10]; char s_year[10]; char ...
2015-09-02 02:46:00
832
转载 MFC中Format函数
在MFC程序中,使用CString来处理字符串是一个很不错的选择。CString既可以处理Unicode标准的字符串,也可以处理ANSI标准的字符串。CString的Format方法给我们进行字符串的转换带来了很大的方便,比如常见的int、float和double这些数字类型转换为CString字符串只需一行代码就可以实现。 先看看Format用于转换的格式字符: %c...
2015-09-02 02:44:00
311
转载 MFC连接SQL Server数据库
C++连接SQL数据库分步骤进行我们在进行C++连接SQL数据库的操作时,首先应该进行相应的系统配置,然后初始化C++与SQL连接,然后再进行数据连接的操作,然后应用SQL执行语言来具体操作。C++连接SQL数据库第一步 系统配置1.设置SQLSERVER服务器为SQL登录方式,并且系统安全性中的sa用户要设置登录功能为“启用”,还有必须要有密码。2.需要在ODBC中进...
2015-09-02 02:38:00
1059
转载 strcpy、strncpy、strcmp、strncmp、strlen源码
strcpy#include <string.h>#include <assert.h>char * strcpy( char *strDest, const char *strSrc ) //将源字符串加const,表明其为输入参数{ assert( (strDest != NULL) &&(strSrc != NULL) ); //对源地址...
2015-09-02 02:22:00
138
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人