首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > VC/MFC >

对话框程序中工具条按钮的有关问题

2012-01-28 
对话框程序中工具条按钮的问题?现在在对话框程序中想加排工具条,比如说有“另存为”“保存”“打印”等按钮,现在

对话框程序中工具条按钮的问题?
现在在对话框程序中想加排工具条,比如说有“另存为”“保存”“打印”等按钮,现在问题是这些按钮的功能怎么实现啊?哪有这些代码?谢谢

[解决办法]
看 MSDN CToolBar

Visual C++ provides you with two methods to create a toolbar. To create a toolbar resource using the Resource Editor, follow these steps: 
1 Create a toolbar resource.
2 Construct the CToolBar object.
3 Call the Create (or CreateEx) function to create the Windows toolbar and attach it to the CToolBar object.
4 Call LoadToolBar to load the toolbar resource. 

[解决办法]
工具栏按钮是和菜单项对应的,实现菜单就是实现工具栏

热点排行