Hi,

Here is the source file I'm trying to compile from my last message I posted. For some reason, it keeps giving me an end of file error in VC++6.0. What's wrong with the file?

Code:
// win.cpp: Implementation of the structure win;
      //          After compiling, link with application-file

      #include "win.h"

      win::win(HINSTANCE hInstance0, int iCmdShow0, 
               PSTR szAppName0, PSTR szWindowCaption0)
      { iCmdShow = iCmdShow0;

        //store the arguments for CreateWindow in the structure win:
        szAppName = szAppName0;
        szWindowCaption = szWindowCaption0;
        dwStyle = WS_OVERLAPPEDWINDOW;
        x = y = 0;
        nWidth = GetSystemMetrics(SM_CXSCREEN);
        nHeight = GetSystemMetrics(SM_CYSCREEN);
        hWndParent = NULL;
        hMenu = NULL;
        hInstance = hInstance0;
        lpParam = NULL;

        //Fill wndclass just for now:
        wndclass.cbSize = sizeof(wndclass);
        wndclass.style = CS_HREDRAW | CS_VREDRAW;
        wndclass.lpfnWndProc = WndProc;
        wndclass.cbClsExtra = 0;
        wndclass.cbWndExtra = 0;
        wndclass.hInstance = hInstance;
        wndclass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
        wndclass.hCursor = LoadCursor(NULL, IDC_ARROW);
        wndclass.hbrBackground = (HBRUSH)GetStockObject(WHITE_BRUSH);
        wndclass.lpszMenuName = NULL;
        wndclass.lpszClassName = szAppName;
        wndclass.hIconSm = LoadIcon(NULL, IDI_APPLICATION);
        wndclass.hIconSm = LoadIcon(NULL, IDI_APPLICATION);
        hDlg=0;
        szAccel = NULL;
      }

      int win::result()
      { RegisterClassEx(&wndclass);
        hWnd = CreateWindow(szAppName, szWindowCaption, dwStyle,
               x, y, nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam);
        ShowWindow(hWnd, iCmdShow);
        UpdateWindow(hWnd);
        MSG msg;
        HACCEL hAccel = (szAccel ? LoadAccelerators(hInstance, szAccel) : 0);
        while (GetMessage(&msg, NULL, 0, 0))
        { if (hDlg == 0 || !IsDialogMessage(hDlg, &msg))
          { if (hAccel == 0 || !TranslateAccelerator(hWnd, hAccel, &msg))
            { TranslateMessage(&msg);
              DispatchMessage(&msg);
            }
          }
        }
        return msg.wParam;
      }
Any help would be greatly appreciated..

DAn