随笔分类 -  C/C++

摘要:测试Rockey4Smart加密锁之模块字和三算法的用法C#代码private void btn_LookZzghjk_Click(object sender, EventArgs e) { if (this.r == null) { MessageBox.Show("先执行[查找加密锁]!", "提示"); return; } string val = ""; string sn = ""; ... 阅读全文
posted @ 2012-05-10 18:22 sqlite例子 阅读(302) 评论(0) 推荐(0)
摘要:ArcEngine+VC6二次开发之添加MapControl控件封装应用类系统开发环境如下所示://---------------------------ArcGIS Engine 9.3 Runtime+SDKVC6.0//---------------------------添加MapControl控件封装应用类打开IDD_AOEX_FORM主对话框选中ArcGIS Engine MapControl控件点击右键弹出菜单,再点击建立类向导菜单项弹出MFC ClassWizard对话框选中Member Variables选项卡Project: AoExClass name:CAoExView 阅读全文
posted @ 2012-05-08 11:54 sqlite例子 阅读(336) 评论(0) 推荐(0)
摘要:ArcEngine+VC6二次开发添加ESRI MapControl不支持此接口的解决办法系统开发环境如下所示:ArcGIS Engine 9.3 Runtime+SDKVC6.0一、创建一个VC工程 使用AppWizard来创建MFC工程(选择File->New->Project Workspace菜单, 这时弹出创建向导对话框,工程命名为AoEx,按照创建向导创建工程的步骤如下: (1)在Step 1中,选择"Single Document" 作为工程的应用类型; (2)在Step 2中,选择缺省值; (3)在Step 3中,选择"ActiveX 阅读全文
posted @ 2012-05-08 10:03 sqlite例子 阅读(237) 评论(0) 推荐(0)
摘要:测试Rockey 4 Smart加密锁的.Net C#语言代码public enum Ry4Cmd : ushort { RY_FIND = 1, //Find Ry4S RY_FIND_NEXT, //Find next RY_OPEN, //Open Ry4S RY_CLOSE, //Close Ry4S RY_READ, //Read Ry4S RY_WRITE, //Write Ry4S RY_RANDOM, //Generate rando... 阅读全文
posted @ 2012-04-26 18:15 sqlite例子 阅读(496) 评论(0) 推荐(0)
摘要:测试Rockey 4 Smart加密锁的C语言代码// win32Console_dog_test.cpp : Defines the entry point for the console application. /////////////////////////////////////// // //测试Rockey 4 Smart加密锁的C语言代码 // /////////////////////////////////////// #include "stdafx.h" #include <conio.h> #include "time.h& 阅读全文
posted @ 2012-04-26 18:06 sqlite例子 阅读(305) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之六(mapgis公用函数二次封装库)/////////////////////////////////////////// //mapgis_common.cpp //mapgis公用函数二次封装库 //vp:hsg //create date:2012-04 // /////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include &quo 阅读全文
posted @ 2012-04-20 17:14 sqlite例子 阅读(296) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之五(输出VCT函数之表属性段)////////////////////////////////////////////// // //输出vct属性值 version=1, topo=0 //vp:hsg //create date:2012-04-20 // ////////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include &quo 阅读全文
posted @ 2012-04-20 17:06 sqlite例子 阅读(176) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之五(输出VCT函数之面图层)////////////////////////////////////////////// // //输出vct面坐标 version=1, topo=0 //vp:hsg //create date:2012-04-20 // ////////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include " 阅读全文
posted @ 2012-04-20 17:04 sqlite例子 阅读(246) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之五(输出VCT函数之线图层)////////////////////////////////////////////// // //输出vct线坐标 version=1, topo=0 //vp:hsg //create date:2012-04-20 // ////////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include " 阅读全文
posted @ 2012-04-20 17:02 sqlite例子 阅读(218) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之五(输出VCT函数之点图层)////////////////////////////////////////////// // //输出vct点坐标 version=1, topo=0 //vp:hsg //create date:2012-04-20 // ////////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include " 阅读全文
posted @ 2012-04-20 17:00 sqlite例子 阅读(173) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之五(输出VCT函数 总入口)////////////////////////////////////////////// // //VCT 导出功能 version=1, topo=0 //vp:hsg //create date:2012-04-20 // ////////////////////////////////////////////// #include "stdafx.h" #include "resource.h" #include <math.h> #include " 阅读全文
posted @ 2012-04-20 16:25 sqlite例子 阅读(210) 评论(0) 推荐(0)
摘要:C/C++ 去掉字符串首尾空格函数//去掉字符串首(左)空格函数 char* ltrim_lc(char* s) { char* s_s=new char[strlen(s)+1]; strcpy(s_s,s); char* s_rev=strrev(s_s); s_rev=rtrim_lc(s_rev); char* d_s=strrev(s_rev); return d_s; } //去掉字符串尾(右)空格函数 char* rtrim_lc(char* s) { char* s_s=new char[strlen(s)+1]; strcpy(s_s,s); /... 阅读全文
posted @ 2012-04-20 10:41 sqlite例子 阅读(959) 评论(0) 推荐(0)
摘要:C/C++ 分割字符并返回字符数组实例//分割字符并返回字符数组 char **GetStrArray(char* s,const char* d) { char* s_s=new char[strlen(s)]; strcpy(s_s,s); //计算字符数组个数 int rows=0; char *p_str=strtok(s_s,d); while(p_str) { rows+=1; p_str=strtok(NULL,d); } //重新初始二维数据 char **strArray=new char*[rows+1... 阅读全文
posted @ 2012-04-19 17:31 sqlite例子 阅读(567) 评论(0) 推荐(0)
摘要:C/C++二维数据 静态动态声明和初始化及访问方法实例void D2A_test() { int rows=3; int cols=4; int i,j; int *p; char* pret; //静态声明二维数据 /* int a[3][4]={{1,2,3,4},{11,12,13,14},{21,22,23,24}}; //赋值 for(i=0;i<rows;i++) { for(j=0;j<cols;j++) { a[i][j]=i*4+j; } } // p=a[0]; //数组首地址 //一般二维数据读... 阅读全文
posted @ 2012-04-19 15:44 sqlite例子 阅读(197) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之四(VCT导出之 version=1,topo=0)本文所述内容为国土行业的VCT版本为1,拓扑=0的结构即为2002年国家标准本文主要包括有(vct文件头段输出功能;vct要素类段输出功能;vct字段结构输出功能;vct线要素几何图形输出功能;vct属性结构输出功能;)其中vct点要素几何图形输出功能; vct面要素几何图形输出功能; vct注记几何图形输出功能;将在后续的文章中描述;//Vct_Export.cpp文件内容如下所示:////////////////////////////////////////////// // /... 阅读全文
posted @ 2012-04-18 18:10 sqlite例子 阅读(287) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之三(文件操作通用函数)//FileOpClass.cpp文件内容如下所示:////////////////////////////////////////////////////////////////// // //文件操作 //#include FileOpClass // ////////////////////////////////////////////////////////////////// #include "demo.h" char* LogFileName="AppErrorLog.log&qu 阅读全文
posted @ 2012-04-18 17:58 sqlite例子 阅读(187) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之二(主窗体回调函数)Map_cpak.cpp文件内容如下所示://添加处理鼠标消息的函数 //回调函数 //*****************************************************// //Map_cpak.cpp // 回调函数模块: // 集中窗口的回调函数 //*****************************************************// #include "stdafx.h" #include "resource.h" #include 阅读全文
posted @ 2012-04-18 17:55 sqlite例子 阅读(302) 评论(0) 推荐(0)
摘要:mapgis6.7二次开发vc6_demo 之一(主窗体构架)本文根据mapgis6.7 sdk开发包中实例程序和help.chm帮助文件进行的学习心得总结://stdafx.h文件内容如下所示 :#include <windows.h>//#include "demo.h"文件内容如下所示 ://#include "demo.h" #if !defined(AFX_DEMO_H__8E07CFE6_850E_11D4_9287_444553540000__INCLUDED_) #define AFX_DEMO_H__8E07CFE6_850 阅读全文
posted @ 2012-04-18 17:49 sqlite例子 阅读(402) 评论(0) 推荐(0)