TBBUTTON button[12];
int i=0,nStringLength;
CString string;
TCHAR * pString; 
int m_StatusItemWidth[3];
CString StatusText;
//建立ImageList对象及ToolBar对象
m_ImageList.Create(32,32,ILC_COLOR32|ILC_MASK,0,0);     //创建一个图象列表框
m_ToolBar.EnableAutomation();
m_ToolBar.Create(WS_CHILD|WS_VISIBLE,CRect(0,0,0,0),this,ID_TOOLBAR);
//向ImageList对象中添加资源图标
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(1))); //向图像列表框中添加图片
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON1))); //向图像列表框中添加图片
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON1)));
for(i=IDI_ICON2;i<=IDI_ICON4;i++)
{
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(i))); //向图像列表框中添加图片
}
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON1)));
for(i=IDI_ICON5;i<=IDI_ICON6;i++)
{
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(i))); //向图像列表框中添加图片
}
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON1)));
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON7))); //向图像列表框中添加图片
m_ImageList.Add(::LoadIcon(::AfxGetResourceHandle(),MAKEINTRESOURCE(IDI_ICON14))); //向图像列表框中添加图片 m_ToolBar.SetImageList(&m_ImageList);   
for(i=0;i<=11;i++)
{
button[i].dwData=0;
button[i].fsState=TBSTATE_ENABLED;
if(i==1 ||i==5||i==8)
button[i].fsStyle=TBSTYLE_SEP ;
else
button[i].fsStyle=TBSTYLE_BUTTON ;
button[i].iBitmap=i;
string.LoadString(i + IDS_STRING1);//装载字符串资源
//为每一个字符串再加一个'\0',用于向工具栏里加字符串
nStringLength= string.GetLength() + 1;
pString = string.GetBufferSetLength(nStringLength);
//返回刚加的字符串的编号
button[i].iString =m_ToolBar.AddStrings(pString);
string.ReleaseBuffer();
}
button[0].idCommand=ID_MnuItemWare;
button[2].idCommand=ID_MnuItemReserve;
button[3].idCommand=ID_MnuItemSell;
button[4].idCommand=ID_MnuItemSellBack;
button[6].idCommand=ID_MnuItemReserveQuery;
button[7].idCommand=ID_MnuItemSellQuery;
button[9].idCommand=ID_MnuItemSystem;
button[10].idCommand=ID_MnuItemBack;

m_ToolBar.AddButtons(11,button); 
m_ToolBar.AutoSize();
m_ToolBar.SetStyle(TBSTYLE_FLAT|CCS_TOP);
上面这段代码中button[0].idCommand=ID_MnuItemWare;
button[2].idCommand=ID_MnuItemReserve;
button[3].idCommand=ID_MnuItemSell;
button[4].idCommand=ID_MnuItemSellBack;
button[6].idCommand=ID_MnuItemReserveQuery;
button[7].idCommand=ID_MnuItemSellQuery;
button[9].idCommand=ID_MnuItemSystem;
button[10].idCommand=ID_MnuItemBack;
这里是什么意思呀那些ID是什么呀在哪里设置的呀
指教一下谢谢了啊