VS2012 MFC应用程序 ODBC SQL2005 数据库连接

来源:互联网 发布:冰川网络 高祥 编辑:程序博客网 时间:2024/05/19 19:31

 

MFC ODBC 数据源配置向导 生成CRecordset派生类

 

 

 

 

界面运行效果图

 

数据格式转换

//CString --> FloatCString m_temp;float temp = (float)_tstof(m_temp.GetBuffer(0));
 //CTime --> CStringCString s = tLive.m_time.Format( "%Y/%m/%d%H:%M:%S" );
 //CTime --> CStringCString temp;temp.Format(_T("%.2f"),tLive.m_temp);
//long --> CStringCString temp;m_eResult = temp;temp.Format(_T("%ld"),tLive.m_id);
 
原创粉丝点击