How do i put a .bmp onto a button? And how do i play MP3 files?
Printable View
How do i put a .bmp onto a button? And how do i play MP3 files?
To put an icon on a button check the button's bitmap check box and thn add this code
Code:HBITMAP hBit = (HBITMAP)LoadImage(NULL,"C:\\windows\\bubbles.bmp",IMAGE_BITMAP,0,0,LR_LOADFROMFILE);
butt1.SetBitmap (hBit); //butt1 is the var for
//This is for MFC only
Here is a zip file that says how to decode and play MP3 files without using any DLL's
BTW, to make a button have a pic on it, you would have to use te GetDC API on the hWnd of a button, then BitBlt the pic onto it...
[Edited by denniswrenn on 11-13-2000 at 02:39 PM]
Vlatko, im not using MFC.
Dennis, thanks ill check it out.