读书人

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

发布时间: 2012-01-28 22:06:13 作者: rapoo

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

[解决办法]
看 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.

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

读书人网 >VC/MFC

热点推荐