摘要: 1、在测试编写继承CStatic类组件时候,发现在调用调试过程中弹出一个错误,点忽略还可以继续运行。如下图:2、dlgdata.cpp此文件是VS安装目录\Microsoft Visual Studio .NET 2003\Vc7\atlmfc\src\mfc中的文件,而出现此错误一般是所使用的组件有问题,此项目中我直接使用了自带的CStatic(caption:TODO:在此旋转对话框控件)。再添加一个CStatic(caption:Static),结果发现这两个CStatic的ID竟然是一样的IDC_STATIC,此时大约有结论了:应该是ID冲突(IDC_STATIC这个ID应该是默认绑定 阅读全文
posted @ 2013-10-31 10:00 Faint@LastStep 阅读(911) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加类CDllDailog3、切换到Resource view界面,添加新Button(ID:IDC_BUTTON_Hello Caption:Hello),并点击进入DllDialog.cpp脚本,添加代码如下(红色): 1 #include "stdafx.h" 2 #include "dllTest.h" 3 #include "DllDialog.h" 4 #include ".\dlldialog.h" 5 6 7 // CDllDial 阅读全文
posted @ 2013-10-30 11:58 Faint@LastStep 阅读(419) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本point.h,代码如下: 1 #ifndef POINT_H 2 #define POINT_H 3 4 #ifdef DLL_FILE 5 class _declspec(dllexport) point //导出类point 6 #else 7 class _declspec(dllimport) point //导入类point 8 #endif 9 {10 public:11 float y;12 float x;13 point();14 point(float x_c... 阅读全文
posted @ 2013-10-28 15:53 Faint@LastStep 阅读(281) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本lib.h,代码如下: 1 #ifndef LIB_H 2 #define LIB_H 3 extern int dllGlobalVar; 4 extern "C" int GetGlobalVar(); 5 extern "C" void SetGlobalVar(int value); 6 //为了验证全局的字符变量定义导出dllGlobalStr 7 extern char *dllGlobalStr; 8 extern "C" char *GetGl 阅读全文
posted @ 2013-10-28 10:03 Faint@LastStep 阅读(360) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本lib.h,代码如下:1 #ifndef LIB_H2 #define LIB_H3 int _stdcall add(int x,int y);4 int _cdecl mius(int x,int y);5 #endif 3、项目dllTest中添加脚本lib.cpp,代码如下: 1 #include "lib.h" 2 #include "windows.h" 3 #include "stdio.h" 4 5 BOOL APIENTRY DllMain( 阅读全文
posted @ 2013-10-25 15:23 Faint@LastStep 阅读(474) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本lib.h,代码如下:1 #ifndef LIB_H2 #define LIB_H3 extern "C" int add(int x,int y);4 extern "C" int mius(int x,int y);5 #endif 3、项目dllTest中添加脚本lib.cpp,代码如下: 1 #include "lib.h" 2 #include "windows.h" 3 #include "stdio.h" 阅读全文
posted @ 2013-10-25 11:32 Faint@LastStep 阅读(896) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本lib.h,代码如下:1 //lib.h2 #ifndef LIB_H3 #define LIB_H4 extern "C" int add(int x,int y);5 extern "C" int mius(int x,int y);6 #endif 3、项目dllTest中添加脚本lib.cpp,代码如下: 1 //lib.cpp 2 #include "lib.h" 3 int add(int x,int y) 4 { 5 return x + y; 阅读全文
posted @ 2013-10-24 15:07 Faint@LastStep 阅读(549) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建DLL项目dllTest2、项目dllTest中添加脚本lib.h,代码如下:1 //lib.h2 #ifndef LIB_H3 #define LIB_H4 extern "C" int __declspec(dllexport) add(int x,int y);5 extern "C" int __declspec(dllexport) mius(int x,int y);6 #endif 3、项目dllTest中添加脚本lib.cpp,代码如下:1 #include "lib.h"2 int add(int 阅读全文
posted @ 2013-10-24 13:51 Faint@LastStep 阅读(357) 评论(0) 推荐(0) 编辑
摘要: 1、VS2003新建Static DLL项目libTest2、项目libTest中添加脚本lib.h,代码如下:1 //lib.h2 #ifndef LIB_H3 #define LIB_H4 extern "C" int add(int x,int y);5 extern "C" int mius(int x,int y);6 #endif3、项目libTest中添加脚本lib.cpp,代码如下: 1 //lib.cpp 2 #include "lib.h" 3 int add(int x,int y) 4 { 5 return x 阅读全文
posted @ 2013-10-24 13:19 Faint@LastStep 阅读(229) 评论(0) 推荐(0) 编辑
摘要: 今天整理下看过的JAVA资料信息:1、JAVA编程词典,通看一遍,了解了JAVA的一些基础和IDE工具,可以调些简单的程序,但对JAVA的结构还是迷糊2、MyEclipse 6 Java开发中文教程,看到Hibernate章节就看不下去了,按照教程,始终调不通MySQL例程,感觉有点复杂,回想下还是对JAVA整个体系不清晰。3、想想还是对基础不太熟悉,太急躁了点,虽然有类似的语言基础,但还是要把JAVA当成一个新语言去学习,这次决定从基础开始一章一章开始。4、先了解JAVA的整个体系:J2SE,J2EE,J2ME; JDK(API+RELEASE+JVM); 三层架构(表现+业务+数据); 组 阅读全文
posted @ 2012-12-28 21:46 Faint@LastStep 阅读(179) 评论(0) 推荐(0) 编辑