Click here to Skip to main content
16,008,075 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: typecasting CString to LPSTR Pin
Michael Dunn17-Dec-01 11:01
sitebuilderMichael Dunn17-Dec-01 11:01 
GeneralRe: typecasting CString to LPSTR Pin
Navin17-Dec-01 14:08
Navin17-Dec-01 14:08 
GeneralAdd User Dialog Pin
Ed K17-Dec-01 9:49
Ed K17-Dec-01 9:49 
GeneralCurious Pin
17-Dec-01 9:07
suss17-Dec-01 9:07 
GeneralRe: Curious Pin
Joaquín M López Muñoz17-Dec-01 9:19
Joaquín M López Muñoz17-Dec-01 9:19 
GeneralRe: Curious Pin
17-Dec-01 9:22
suss17-Dec-01 9:22 
GeneralRe: Curious WHOOPS Pin
17-Dec-01 9:30
suss17-Dec-01 9:30 
GeneralRe: Curious WHOOPS Pin
Joaquín M López Muñoz17-Dec-01 9:45
Joaquín M López Muñoz17-Dec-01 9:45 
I'm really new to programming, so please bear with me.

Glad to be helpful Wink | ;) I'll give you as thorough an explanation as I can (forgive me if some details are already obvious to you).
Well, There's four steps in getting the process done:
  1. Have a bitmap loaded in your resources. I'm assuming the identifier of the bitmap is IDB_BACKGROUND but you can change it to whatever pleases you most.
  2. Add the two variables m_bitmap_background and m_bmInfo_background. The way to do it you suggest is just fine (types are CBitmap and BITMAP, respectively). You can also edit by hand the .h and insert directly the variables.
  3. Locate the OnInitDialog of your dialog and insert the stuff where m_bitmap_background and m_bmInfo_background are set their values.
  4. Go to the class wizard (CTRL+W on most IDE installations) and add a message handler for WM_ERASEBKGND. This gets you the OnEraseBkgnd method where you can insert the remaining piece of code.
Good luck and welcome to MFC programming!

Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
GeneralRe: Curious WHOOPS Pin
17-Dec-01 10:50
suss17-Dec-01 10:50 
GeneralRe: Curious WHOOPS Pin
Joaquín M López Muñoz17-Dec-01 11:04
Joaquín M López Muñoz17-Dec-01 11:04 
GeneralRe: Curious Thanks Pin
17-Dec-01 14:20
suss17-Dec-01 14:20 
GeneralSupport to Graph Pin
Tony Li17-Dec-01 8:30
Tony Li17-Dec-01 8:30 
GeneralRe: Support to Graph Pin
Joaquín M López Muñoz17-Dec-01 8:41
Joaquín M López Muñoz17-Dec-01 8:41 
GeneralSocket Communications - buffering problems Pin
Ted Christiansen17-Dec-01 7:58
Ted Christiansen17-Dec-01 7:58 
GeneralRe: Socket Communications - buffering problems Pin
Joaquín M López Muñoz17-Dec-01 9:05
Joaquín M López Muñoz17-Dec-01 9:05 
GeneralHatched Brushes + a Scrolling View = Wacky Lines Pin
D.D. de Kerf17-Dec-01 5:15
D.D. de Kerf17-Dec-01 5:15 
GeneralRe: Hatched Brushes + a Scrolling View = Wacky Lines Pin
Joaquín M López Muñoz17-Dec-01 5:29
Joaquín M López Muñoz17-Dec-01 5:29 
GeneralMAXIMIZE A DIALOG Pin
jafrazee17-Dec-01 4:42
jafrazee17-Dec-01 4:42 
GeneralRe: MAXIMIZE A DIALOG Pin
Ernest Laurentin17-Dec-01 5:14
Ernest Laurentin17-Dec-01 5:14 
GeneralRe: MAXIMIZE A DIALOG Pin
Eugene Pustovoyt17-Dec-01 8:25
Eugene Pustovoyt17-Dec-01 8:25 
GeneralRe: MAXIMIZE A DIALOG Pin
jafrazee17-Dec-01 9:58
jafrazee17-Dec-01 9:58 
GeneralCalcWindowRect for CFrameWnd Pin
17-Dec-01 4:38
suss17-Dec-01 4:38 
GeneralRe: CalcWindowRect for CFrameWnd Pin
Michael Dunn17-Dec-01 7:28
sitebuilderMichael Dunn17-Dec-01 7:28 
GeneralRe: CalcWindowRect for CFrameWnd Pin
17-Dec-01 8:14
suss17-Dec-01 8:14 
GeneralRe: CalcWindowRect for CFrameWnd Pin
Joaquín M López Muñoz17-Dec-01 8:27
Joaquín M López Muñoz17-Dec-01 8:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.