Crating status bar windows is easy enough, you just need to use CreateStatusWindow function and you won’t forget to set WS_VISIBLE and WS_CHILD flag, would you?
When you are trying to set the background color of the status bar it’s easy again, if its simple, you just need to send SB_SETBKCOLOR message to status part. But the fun starts when you have set parts in your status bar. In this case parts would have the default color,so it would look as if border color has been setup.
To solve this issue you would need handle WM_DRAWITEM message in your WndProc. The lParam in this case is a pointer to LPDRAWITEMSTRUCT.
Eg.: code inside WM_DRAWITEM
LPDRAWITEMSTRUCT lpDrawStruct;
HBRUSH hBrush;
lpdis= (LPDRAWITEMSTRUCT) lParam;
hBrush=CreateSolidBrush(RGB(255,0,0));
FillRect(lpDrawStruct->hDC, &lpDrawStruct->rcItem, hBrush);