当前位置:网站首页>MFC handy notes
MFC handy notes
2022-07-26 09:33:00 【Flying 123_ one hundred and twenty-three】
1、cstring go to char*
CString strPort;
USES_CONVERSION;
char* port = (LPSTR)(LPCSTR)strPort; //cstring go to char*
2、 obtain combo box Information about
CString strPort;
CComboBox* pComboPort = (CComboBox*)GetDlgItem(IDC_COMBO_PORT);
pComboPort->GetWindowText(strPort);
3、 Get and set button Information on the button
CString str;
GetDlgItemText(IDC_BUTTON_OPEN, str);// Get the information on the button
CButton* pBtnOpen = (CButton*)GetDlgItem(IDC_BUTTON_OPEN);
pBtnOpen->SetWindowText(_T(" close "));// Set the information on the button
4、 Set up button
GetDlgItem(IDC_BUT_RunStatus)->EnableWindow(FALSE);// Turn grey , Unavailable , so
GetDlgItem(IDC_BUT_RunStatus)->EnableWindow(TRUE);// Restore to normal , You can use , so
5、String It's transformed into int type
int m_Index;
CString index;
m_Index = _ttoi(index);
6、C***Dialog Call the master C***View
1) add to #include "C***Doc.h" And #include "C***View.h" The header file
2)C***Dialog Add in CView Base class pointer m_pView.
3)C**View Created in Dialog Time assignment C***Dialog.m_pView=this
4)C***Dialog Call in function ((C***View)*m_pView)->Function();
边栏推荐
- (1) Hand eye calibration of face scanner and manipulator (eye on hand)
- Implementation of fragment lazy loading after multi-layer nesting
- OpenCV 表格识别之表格提取(二)
- JS one line code to obtain the maximum and minimum values of the array
- The provincial government held a teleconference on safety precautions against high temperature weather across the province
- antUI中a-modal 拖拽功能制作
- Registration module use case writing
- docker配置mysql集群
- EOJ 2020 1月月赛 E数的变换
- 暑假第四周
猜你喜欢
随机推荐
简单行人重识别代码到88%准确率 郑哲东 准备工作
TabbarController的封装
v-premission添加权限
“互联网+”时代的现代医学
Basic use of ArcGIS 4
WARNING: [pool www] server reached pm.max_children setting (5), consider raising it
Redis sentinel mode setup under Windows
服务器、客户端双认证
Solve "note: one or more layouts are missing the layout_width or layout_height attributes."
JS判断数据类型 Object.prototype.toString.call和typeof
服务器、客户端双认证(2)
Windows下Redis哨兵模式搭建
JS one line code to obtain the maximum and minimum values of the array
Gauss elimination
MySql5.7.25源码安装记录
nodejs中mysql的使用
Force deduction brush questions, sum of three numbers
Antd treeselect gets the value of the parent node
2019 ICPC Asia Yinchuan regional (water problem solution)
Drawing shadow error diagram with MATLAB



![[Online deadlock analysis] by index_ Deadlock event caused by merge](/img/67/0a02ad248c3ab21d3240e12aa23313.png)





