If you're getting _BmpButnProc@16 as already defined then you are using the BmpButton procedure in it's normal way earlier in the program. You can just remove the other BmpButnProc completely but keep in mind that it is required if you don't make a call to BmpButton from the library.

Should work though, are you using:

invoke BitmapFromResource, hInstance, 174
mov Set,eax
invoke BitmapFromResource, hInstance, 173
mov Set2,eax
invoke BmpButton2,hWin,92,37,Set,Set2,500
Posted on 2003-06-08 20:49:59 by donkey
It uses

invoke BitmapFromResource, hInstance, 2000
mov hBmp, eax

To get a bitmap handle and in the paint proc it selects the handle into a memdc and bit block transfers it onto the window:

invoke CreateCompatibleDC,hDC
mov memDC, eax

invoke SelectObject,memDC,hBmp
mov hOld, eax

invoke BitBlt,hDC,0,1,550,175,memDC,0,0,SRCCOPY
Posted on 2003-06-08 20:53:33 by donkey
so if I moved it to 0,0 would I be able to use the jpg as a background? Bmps work well but they inflate the filesize like mad..
Posted on 2003-06-08 20:58:24 by EEDOK
Yeah, sure. You can just use the Paint proc from it and ofcourse process the WM_PAINT message. Set hBmp to whatever bitmap handle you want. If you want to use a JPG use the BitmapFromResource function to extract a bitmap handle from a JPEG resource image.
Posted on 2003-06-08 21:04:30 by donkey
thnx again Donkey, by changing the bg to jpg it reduced the filesize by 72% :P but I think that 66% conversion from resource units to pixels is pretty accurate..
Posted on 2003-06-08 21:30:58 by EEDOK
Yeah, the 66% would be close as long as you're using the default font I geuss but I would never settle for an approximation, just me I geuss. I once wrote a RES file extractor that had to calculate them and it is a little complicated. I always use the resource editor with RadASM so I never have to worry about the conversion.
Posted on 2003-06-09 01:14:43 by donkey