News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

mysleep proc

Started by clamicun, January 28, 2017, 02:38:02 AM

Previous topic - Next topic

jj2007

Writing "does not compile" is a no-no. Every compiler spits out error messages, and it would be extremely helpful to show them here. Btw did you use BSTYLE_DROPDOWN as posted above, or TBSTYLE_DROPDOWN?

TWell

My test:.model flat

TBBUTTON STRUCT
iBitmap DWORD ?
idCommand DWORD ?
fsState BYTE ?
fsStyle BYTE ?
; bReserved BYTE 6 DUP (?) ; x64
; bReserved BYTE 2 DUP (?) ; x86
bReserved DWORD ?
dwData DWORD PTR ?
iString DWORD PTR ?
TBBUTTON ENDS

TBSTATE_ENABLED = 4h
TBSTYLE_DROPDOWN = 8h
TBSTYLE_AUTOSIZE = 10h
BTNS_DROPDOWN = TBSTYLE_DROPDOWN

LPSTR typedef PTR BYTE

.data
;Start the button IDs at one so we don't use 0 (we'll have to dec in order to get the right menu)
TbBtns TBBUTTON <0,1,TBSTATE_ENABLED,TBSTYLE_AUTOSIZE OR TBSTYLE_DROPDOWN,0,0,0>
       TBBUTTON <1,2,TBSTATE_ENABLED,TBSTYLE_AUTOSIZE OR TBSTYLE_DROPDOWN,0,0,1>
       TBBUTTON <3,3,TBSTATE_ENABLED,TBSTYLE_AUTOSIZE OR TBSTYLE_DROPDOWN,0,0,2>
       TBBUTTON <4,4,TBSTATE_ENABLED,TBSTYLE_AUTOSIZE OR TBSTYLE_DROPDOWN,0,0,3>

END
so check your header or at least tell us what header file you use and what compiler?