• 大小: 11.09MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-07-21
  • 语言: C/C++
  • 标签: TeeChart  C  C++  

资源简介

Visual C++ 的TeeChart Pro Activex control v8 例子源代码

资源截图

代码片段和文件信息

#include “StdAfx.h“
#include “Assist.h“
#include 
CAssist::CAssist(void)
{
}

CAssist::~CAssist(void)
{
}

CString CAssist::GetCString(CString AppName CString KeyName)
{
CString strpaht;
AFX_MANAGE_STATE(AfxGetStaticModuleState());
wchar_t* name=new wchar_t[513];
memset(name0sizeof(name));
::GetModuleFileName(0LPWCH(name)256);
PathRemoveFileSpec(name);
    paht=(CString)name+L“\\DXINFOR.ini“;

::GetPrivateProfileString(AppNameKeyNameNULLstr.GetBuffer(128)128paht);
//::GetPrivateProfileString(AppNameKeyNameNULLstr.GetBuffer(128)128L“.\\DXINFOR.ini“);
    str.ReleaseBuffer();
return str;
}
//设置文本
void CAssist::SetCString(CString AppName CString KeyNameCString str)
{
CString paht;
AFX_MANAGE_STATE(AfxGetStaticModuleState());
wchar_t* name=new wchar_t[513];
memset(name0sizeof(name));
::GetModuleFileName(0LPWCH(name)256);
PathRemoveFileSpec(name);
paht=(CString)name+L“\\DXINFOR.ini“;

::WritePrivateProfileString(AppNameKeyNamestrpaht);
str.ReleaseBuffer();

}
int CAssist::GetInt(CString AppName CString KeyName)
{
CString paht;
AFX_MANAGE_STATE(AfxGetStaticModuleState());
wchar_t* name=new wchar_t[513];
memset(name0sizeof(name));
::GetModuleFileName(0LPWCH(name)256);
PathRemoveFileSpec(name);
paht=(CString)name+L“\\DXINFOR.ini“;

return ::GetPrivateProfileInt(AppNameKeyName0paht);
}

CString CAssist::GetPgain(double error)
{
CString m_str(L““);
double mnd;
d=(-error)/(100+error);
if(d>=0)
{error=ldexp(d15);}
else
{error=ldexp(1.016)+ldexp(d15);}

n=modf(error&m);
int i=(int)m;
m_str.Format(L“%04X“i);
return m_str.Right(4);
}

CString CAssist::Geterr(double error)
{
CString m_str(L““);
double mnd;
d=asin(-error/(sqrt(3.0)*100));
error=d*180.0/PI;

if(error>=0)
{d=error/0.02;}
else
{d=ldexp(1.08)+error/0.02;}
n=modf(d&m);
int i=(int)m;
m_str.Format(L“%02X“i);
return m_str.Right(2);
}

CString CAssist::GetName(CString ope)
{
if(ope==L“getidmod“)
{return L“修改设备“;}
//{return L“修改设备号“;}
if (ope==L“redip“)
{return L“读设备号“;}
if(ope==L“argument“)
{return L“参数复位“;}
if(ope==L“regule“)
{return L“误差复位“;}
if(ope==L“reguleui“)
{return L“校准电压电流“;}
if(ope==L“reguleF“||ope==L“reguleH“)
{return L“校准“;}
if(ope==L“clear“||ope==L“clearmod“)
{return L“清零“;}

if(ope==L“getuip“||L“getuipmod“)
{return L“获取电参“;}
if(ope==L“UP“)
{return L“合闸“;}
if(ope==L“DOWN“)
{return L“拉闸“;}
return L““;
}

CString CAssist::TrimZero(CString num)
{
num.TrimLeft(L“0“);
if(num.Find(L“.“)==0)
{num.Insert(0L“0“);}
return num;
}

// 获取程序当前路径
wchar_t*  CAssist::GetNowPath(void)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
wchar_t* name=new wchar_t[513];
memset(name0sizeof(name));
::GetModuleFileName(0LPWCH(name)256);
PathRemoveFileSpec(name);
return name;
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件    5774336  2012-08-26 18:12  实例(VC2008)\Debug\TeeChar8.exe

     文件    6599696  2008-10-24 13:14  实例(VC2008)\Debug\TeeChart8.ocx

     文件       2972  2012-08-25 20:14  实例(VC2008)\TeeChar8\Assist.cpp

     文件        443  2012-08-23 11:22  实例(VC2008)\TeeChar8\Assist.h

     文件       2887  2012-08-03 19:16  实例(VC2008)\TeeChar8\ReadMe.txt

     文件       1814  2012-08-15 20:15  实例(VC2008)\TeeChar8\res\BCGSoft_ribbon\ribbon.xml

     文件        367  2012-08-15 20:15  实例(VC2008)\TeeChar8\res\BCGSoft_ribbon\TeeChar8.ribbon.rc2

     文件       2096  2012-08-15 20:15  实例(VC2008)\TeeChar8\res\BCGSoft_ribbon\TODO.xml

     文件      67777  2007-11-28 16:21  实例(VC2008)\TeeChar8\res\TeeChar8.ico

     文件        364  2012-08-03 19:16  实例(VC2008)\TeeChar8\res\TeeChar8.rc2

     文件        816  2012-08-16 17:13  实例(VC2008)\TeeChar8\resource.h

     文件        141  2012-08-03 19:16  实例(VC2008)\TeeChar8\stdafx.cpp

     文件       1854  2012-08-03 19:16  实例(VC2008)\TeeChar8\stdafx.h

     文件       1030  2012-08-03 19:16  实例(VC2008)\TeeChar8\targetver.h

     文件        542  2012-08-03 20:28  实例(VC2008)\TeeChar8\tchart1.cpp

     文件      33644  2012-08-04 14:27  实例(VC2008)\TeeChar8\tchart1.h

     文件        934  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\adxfunction.cpp

     文件        808  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\adxfunction.h

     文件       1151  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\amountfilter.cpp

     文件        807  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\amountfilter.h

     文件       6647  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\annotationcallout.cpp

     文件       1940  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\annotationcallout.h

     文件       4933  2008-10-24 11:13  实例(VC2008)\TeeChar8\TeeChar\annotationtool.cpp

     文件       2119  2008-10-24 11:13  实例(VC2008)\TeeChar8\TeeChar\annotationtool.h

     文件       1327  2008-10-24 11:13  实例(VC2008)\TeeChar8\TeeChar\antialiastool.cpp

     文件       1363  2008-10-24 11:13  实例(VC2008)\TeeChar8\TeeChar\antialiastool.h

     文件       7169  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\areaseries.cpp

     文件       2006  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\areaseries.h

     文件       4144  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\arrowseries.cpp

     文件       1465  2008-07-07 12:19  实例(VC2008)\TeeChar8\TeeChar\arrowseries.h

............此处省略592个文件信息

评论

共有 条评论