User Icon and Cursor Example Program in VC++

#include<afxwin.h>
#include<afxext.h>
#include"resource.h"

class Frame : public CFrameWnd {
public:
   CStatic Label[10];
   CButton Button[2];
   CEdit Edit[10];

   Frame() {
      CString Text;
      HBRUSH Brush;
      Brush = ::CreateSolidBrush(RGB(255, 0, 255));
      Text = AfxRegisterWndClass(CS_HREDRAW | CS_VREDRAW, AfxGetApp()->LoadCursor(IDC_CURSOR1), Brush, AfxGetApp()->LoadIcon(IDI_ICON1));
      Create(Text, "User ICON and Cursor");
   }
};

class Applet : public CWinApp {
public:

   int InitInstance() {
      Frame *Pointer;
      Pointer = new Frame();
      Pointer->ShowWindow(3);
      m_pMainWnd = Pointer;
      return 1;
   }
};
Applet Instance;