Click here to Skip to main content
14,981,456 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: _asm Pin
Eytukan10-Jan-06 2:37
MemberEytukan10-Jan-06 2:37 
GeneralRe: _asm Pin
David Crow10-Jan-06 2:40
MemberDavid Crow10-Jan-06 2:40 
GeneralRe: _asm Pin
Nish Nishant10-Jan-06 4:17
sitebuilderNish Nishant10-Jan-06 4:17 
GeneralRe: _asm Pin
Eytukan10-Jan-06 4:20
MemberEytukan10-Jan-06 4:20 
AnswerRe: _asm Pin
Stephen Hewitt10-Jan-06 3:05
MemberStephen Hewitt10-Jan-06 3:05 
AnswerRe: _asm Pin
Nish Nishant10-Jan-06 4:20
sitebuilderNish Nishant10-Jan-06 4:20 
AnswerRe: _asm Pin
vikas amin11-Jan-06 20:36
Membervikas amin11-Jan-06 20:36 
QuestionCustomizing a toolbar Pin
Ward10-Jan-06 0:58
MemberWard10-Jan-06 0:58 
I've used the following code to create the toolbar window:

<br />
hToolbar = CreateWindowEx(0,TOOLBARCLASSNAME,"MyToolbar",CCS_ADJUSTABLE|WS_CHILD|WS_VISIBLE|TBS_TOOLTIPS,0,0,0,0,hWnd/*this is a dialog*/,0,g_hInstance,NULL);<br />
SendMessage(hToolbar, TB_BUTTONSTRUCTSIZE, (WPARAM)sizeof(TBBUTTON), 0);<br />
SendMessage(hToolbar,TB_SETBITMAPSIZE, 0,(LPARAM)MAKELONG(32,32));<br />
SendMessage(hToolbar, TB_AUTOSIZE,0,0);<br />

I've added some bitmaps to the toolbar using several calls of
<br />
SendMessage(hToolbar,TB_ADDBITMAP,1,(LPARAM)&bit);<br />

with bit of type TBADDBITMAP
Finally added all my buttons to the toolbar using
<br />
SendMessage(hToolbar, TB_ADDBUTTONS, NUMBEROFTOOLBARBUTTONS, (LPARAM)&tbb);<br />

I've added 5 buttons to the toolbar. The toolbar is perfectly visible and I've even managed to show a toolbar for each button by returning the appropriate data in the TTN_GETDISPINFO notification message.

Now when I send the TB_CUSTOMIZE to the toolbar, I receive following notifications:

TBN_BEGINADJUST: I simply return TRUE here

Then 7(?!: I have only five buttons) TBN_QUERYINSERT notification
I've printed the iItem value of the structure NMTOOLBAR for each notification:
iItem = 5
iItem = 5 (why is this one send twice)
iItem = 4
iItem = 3
iItem = 2
iItem = 1
iItem = 0
I return TRUE for each TBN_QUERYINSERT.

And finally I get the notification TBN_ENDADJUST.

Now where did the notifications TBN_QUERYDELETE and above all TBN_GETBUTTONINFO gone too??
I hope someone can help me out here,

kind regards,







Ward
QuestionDll or ActiveX Pin
zon_cpp10-Jan-06 0:31
Memberzon_cpp10-Jan-06 0:31 
AnswerRe: Dll or ActiveX Pin
ThatsAlok10-Jan-06 0:45
MemberThatsAlok10-Jan-06 0:45 
Questionlooking for a Grid Control Pin
toxcct9-Jan-06 23:47
Membertoxcct9-Jan-06 23:47 
AnswerRe: looking for a Grid Control Pin
ddmcr10-Jan-06 0:05
Memberddmcr10-Jan-06 0:05 
GeneralRe: looking for a Grid Control Pin
toxcct10-Jan-06 0:10
Membertoxcct10-Jan-06 0:10 
AnswerRe: looking for a Grid Control Pin
Cedric Moonen10-Jan-06 0:07
MemberCedric Moonen10-Jan-06 0:07 
GeneralRe: looking for a Grid Control Pin
toxcct10-Jan-06 0:09
Membertoxcct10-Jan-06 0:09 
GeneralRe: looking for a Grid Control Pin
ThatsAlok10-Jan-06 0:17
MemberThatsAlok10-Jan-06 0:17 
GeneralRe: looking for a Grid Control Pin
Rage10-Jan-06 0:22
professionalRage10-Jan-06 0:22 
GeneralRe: looking for a Grid Control Pin
ThatsAlok10-Jan-06 0:35
MemberThatsAlok10-Jan-06 0:35 
GeneralRe: looking for a Grid Control Pin
toxcct10-Jan-06 0:26
Membertoxcct10-Jan-06 0:26 
GeneralRe: looking for a Grid Control Pin
ThatsAlok10-Jan-06 0:41
MemberThatsAlok10-Jan-06 0:41 
GeneralRe: looking for a Grid Control Pin
Cedric Moonen10-Jan-06 0:49
MemberCedric Moonen10-Jan-06 0:49 
GeneralRe: looking for a Grid Control Pin
ThatsAlok10-Jan-06 1:02
MemberThatsAlok10-Jan-06 1:02 
GeneralRe: looking for a Grid Control Pin
#realJSOP10-Jan-06 2:05
mva#realJSOP10-Jan-06 2:05 
QuestionDLL loading problem Pin
kil ramesh9-Jan-06 23:39
Memberkil ramesh9-Jan-06 23:39 
AnswerRe: DLL loading problem Pin
ThatsAlok10-Jan-06 0:27
MemberThatsAlok10-Jan-06 0:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.