类型转换的问题,怎样在MessageBox函数里显示int值?
我要把int 转换成LPCTSTR,怎么办?
我是这样写的,明显不好,各位大虾帮我改改?
#define UNICODE
#include <windows.h>
int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)
{
int a = sizeof(TCHAR);
char str1[1];
itoa(a,str1,10);
MessageBox(NULL,str1,L"123",0);
return 0;
}
另外,MessageBox的函数定义是:MessageBox(HWND,LPCTSTR,LPCTSTR,UINT);
我是这样写的,明显不好,各位大虾帮我改改?
#define UNICODE
#include <windows.h>
int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nShowCmd)
{
int a = sizeof(TCHAR);
char str1[1];
itoa(a,str1,10);
MessageBox(NULL,str1,L"123",0);
return 0;
}
另外,MessageBox的函数定义是:MessageBox(HWND,LPCTSTR,LPCTSTR,UINT);
...全文
相关推荐
MessageBox按钮显示英语或者其他语言
windows开发使用到的MessageBox显示英文或者其他语言方法。
Towards Crazyswarms
转载https://www.bitcraze.io/2015/04/towards-crazyswarms-2/点击打开链接 This weeks Monday post is a guest post written by Wolfgang Hoenig from University of Southern California. What’s better than a sing
Wincc中弹出对话框函数MessageBox参数以及应用
Wincc中弹出对话框函数MessageBox参数以及应用
CFileDialog、AfxMessageBox和MessageBox的显示位置问题
CFileDialog、AfxMessageBox和MessageBox的显示位置问题,有详细的文档和代码工程(vc6.0)
AfxMessageBox()与MessageBox()的区别
AfxMessageBox()与MessageBox()的区别


