How do I add a bitmap to a property sheet
C / C++ / MFC
2
Posts
2
Posters
0
Views
1
Watching
-
I am creating a wizard using VC++ MFC, but I'm having trouble adding a bitmap header to the property sheet. My bitmap gets clipped by the property pages. What is the standard procedure to accomplish this?:confused: Paul Jahans
If what you want is to allocate a little more space on top of the property sheet, add this snippet on your
OnInitDialog()
:CRect rectWnd; GetWindowRect(rectWnd); SetWindowPos(NULL, 0, 0, rectWnd.Width(), rectWnd.Height() + 100, SWP\_NOMOVE | SWP\_NOZORDER | SWP\_NOACTIVATE); CWnd \*pWnd=GetWindow(GW\_CHILD); while(pWnd!=NULL){ CRect rect; pWnd->GetWindowRect(rect); rect.OffsetRect(0,100); ScreenToClient(rect); pWnd->MoveWindow(rect,FALSE); pWnd=pWnd->GetNextWindow(); }
(Of course you'll want to change the offset to fit the dimensions of the bitmap header.) Joaquín M López Muñoz Telefónica, Investgación y Desarrollo