View Single Post
  #1 (permalink)  
Old February 26th, 2005, 08:56 PM
golfbird golfbird is offline
Registered User
 
Join Date: Feb 2005
Location: Mansfield, Ohio, USA.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default chapter 15 problem


    CPen aPen;
    aPen.CreatePen(PS_SOLID, 2, RGB(255,0,0));


Cpen* pOldPen = pDC->SelectObject(&aPen);

following errors occur. since i'm new to this
I have no idea how to correct it. I seem to have
typed in everything in the chapter but need some
help. would appreciate a direct email answer


C:\CPP\sketcher\sketcherView.cpp(67) : error C2065: 'Cpen' : undeclared identifier
C:\CPP\sketcher\sketcherView.cpp(67) : error C2065: 'pOldPen' : undeclared identifier
C:\CPP\sketcher\sketcherView.cpp(67) : error C2440: '=' : cannot convert from 'class CPen *' to 'int'
        This conversion requires a reinterpret_cast, a C-style cast or function-style cast
Generating Code...
Error executing cl.exe.

sketcher.exe - 3 error(s), 0 warning(s)

Peter Boyko