1、
int hScale=1;
int vScale=1;
char hch[10];
char vch[10];
itoa(hScale,hch,10);
itoa(vScale,vch,10);
CString str=_T("比例尺计算")+'\n';
str+=_T("水平比例尺:");
str+=hch;
str+='\n';
str+=_T("垂直比例尺:");
str+=vch;
str+='\n';
str+=_T("是否接受?\n取消则重新捕获");
MessageBox(str,_T("比例尺计算"),MB_OK);
2、
CString strTime,strDate;
strDate.Format(_T("%4d-%2d-%2d"),st.wYear,st.wMonth,st.wDay);
strTime.Format(_T("%02d:%02d:%02d"),st.wHour,st.wMinute,st.wSecond);
strDate+=strTime;
strDate.Format(_T("%4d-%2d-%2d"),st.wYear,st.wMonth,st.wDay);
strTime.Format(_T("%02d:%02d:%02d"),st.wHour,st.wMinute,st.wSecond);
strDate+=strTime;