ich erstelle text labels über:
Code:
HWND CreateLabel(int index,char* Name,int x,int y)
{
return CreateWindow(TEXT("static"), Name, WS_VISIBLE | WS_CHILD, x, y, 490, 15, hwnd, (HMENU) index, NULL, NULL);
}
Code:
SetWindowText(Label2,"Test 1"); später zb SetWindowText(Label2,"Hallo");
!!! Wen ich den code um die background color zu machen entferne funktioniert es dan ist aber der bg halt nen transparent
Code:
case WM_CTLCOLORSTATIC:
/*
if ( GetDlgItem(hwnd, 3) == (HWND)lParam)
{
SetBkMode( (HDC)wParam, TRANSPARENT);
SetTextColor((HDC)wParam, RGB(255,0,0));
return (BOOL) GetStockObject(HOLLOW_BRUSH);
}
if ( GetDlgItem(hwnd, 4) == (HWND)lParam)
{
SetBkMode( (HDC)wParam, TRANSPARENT);
SetTextColor((HDC)wParam, RGB(255,0,0));
return (BOOL) GetStockObject(HOLLOW_BRUSH);
}*/
Ich will eine bitmap aus der resource laden siehe:

Warum geht das nicht ?
Der name stimmt doch ?






