Win32 Application Programming C++, Error with parameter Type LPCWSTR

前端 未结 4 1212
心在旅途
心在旅途 2020-12-07 05:06

I am constructing a program using the Win32 Application on Visual Studio 2013. From the tutorials I have read, I know this following code is correct, but I don\'t know where

4条回答
  •  时光说笑
    2020-12-07 05:41

    LRESULT CALLBACK WinProc(HWND hWnd, UINT Message, WPARAM wParam, LPARAM lParam){
    switch (Message){   
    case WM_PAINT:
        break;
    case WM_CREATE:
    
        break;
    
    case WM_DESTROY:
    
        return 0;
    
    default:
    
        if (IsWindowUnicode(hWnd))
            return DefWindowProcW(hWnd, Message, wParam, lParam);
        else
            return DefWindowProcA(hWnd, Message, wParam, lParam);
        break;
    }
    return 0;}
    

提交回复
热议问题