News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

TB_ADDBUTTONS msg returns an error

Started by Rainstorm, July 11, 2011, 10:46:31 AM

Previous topic - Next topic

Rainstorm

hi
resolved it

xandaz

   just a hint rainstorm.... Instead of doing all those moving opperations just declare a TBBUTTON array and then point the TB_ADDBUTTONS to it.

.const
No_Buttons   equ    10
.data
..
...
MyButtons TBBUTTON <?,0,TBSTATE_ENABLED,TBSTYLE_BUTTON,?,?>
                TBBUTTON <?,1,TBSTATE_ENABLED,TBSTYLE_BUTTON,?,?>
                 ....
                TBBUTTON <?,9,TBSTATE_ENABLED,TBSTYLE_BUTTON,?,?>

Takes less work and works fine....
And also.... are you plaing to make the toolbar invisible at some point? no? just use the WS_VISIBLE style when creating
Bye

Rainstorm

hi xandaz
Quotejust a hint rainstorm.... Instead of doing all those moving opperations just declare a TBBUTTON array and then point the TB_ADDBUTTONS to it.
yes thats what i had done.. the movs were to fill values in the TBUTTON structure..
the code was right in thefirst place.. but it was throwing an error cause i had modified something.. & a return value test.. was working the wrong way

thanks

xandaz