drawing a bitmap in new position
I have some code that draws a bitmap at 0,0 and an edit box that you can input a number to determine the bitmap's position. It's like this:
void DrawPieces(HDC hdcWindow)
hdcMemory = CreateCompatibleDC(hdcWindow);
BitBlt(hdcWindow, xpos, 20, bmXPiece.bmWidth, bmXPiece.bmHeight, hdcMemory, 0, 0, SRCAND);
BitBlt(hdcWindow, xpos, 20, bmXPiece.bmWidth, bmXPiece.bmHeight, hdcMemory, 0, 0, SRCPAINT);
which is called from the WM_PAINT command. It draws it fine, but when I update the variable it doesn't redraw it in a new location. I used the the EN_UPDATE thing on the edit control so it does update the var, and sends it, but the image stays in the same place. How do I make it draw at a different location? Thanks a lot.