Run a search as this gets asked quite a lot.
In your code
What value does hdc have that you are creating a HDC compatible with it?
HDC hdc, hdcMem ; //no init here for hdc
HINSTANCE hInstance ;
GetObject(BITMAP1, sizeof(BITMAP1), &bitmap);
cxSource=bitmap.bmWidth; //why do this if you are not going to use them?
hdcMem=CreateCompatibleDC(hdc); //What is hdc?
BitBlt(hdc, 1, 1, 50, 50, hdcMem, 0, 0, SRCCOPY);
Of course this will only draw it once. When the window needs to be repainted and a WM_PAINT msg is sent you will need to redraw it.
HWND hWnd_Object_To_Paint;//get this HWND with GetDlgItem() ect
For this I would recomend a framebufferDC and screenDC system.
That is all drawing is done to one HDC, the framebuffer. AFTER all the drawing is done the FrameBufferDC is 'copied' [BltBit()] to the screenDC and a paint msg called for with UpdateWindow() or InvalidateRect().
All painting is done with the screenDC. In the paint function the minimum of work is done to ensure it is fast.
Also you must ensure like any memory you create that you free it before using the same handle again or exiting the app.
As I said run a search for more code on this.