Announcement

Collapse
No announcement yet.

initially maximized app ?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • initially maximized app ?

    How should the WinMain-function correctly specify that an app is initially maximized?

    I have tried:
    1) ShowWindow hWnd, %SW_MAXIMIZE
    2) %WS_OVERLAPPEDWINDOW OR %WS_MAXIMIZE in CreateWindow

    Regards
    Peter

  • #2
    This works fine.

    Code:
     
    '-------------------------------------------------------------
    '**Create the Frame window, holds the Client and siblings.
    'szClassName = "MWIND"
    'szWindowTitle = "Virtual Flash Emulator, H8/3644F"
    'Callback = FrameWndProc()
    '-------------------------------------------------------------
    ghWnd = CreateWindowEx(%WS_EX_WINDOWEDGE, _
                          szClassName, _
                          szWindowTitle, _
                          %WS_OVERLAPPEDWINDOW OR %WS_CLIPCHILDREN , _
                          0, 0, _
                          600,400, _
                          %NULL, _
                          ghMenuMain, _
                          hInstance, _
                          BYVAL %NULL)
     
    ShowWindow ghWnd, %SW_MAXIMIZE
    UpdateWindow ghWnd     'force a WM_PAINT
     
    WHILE ISTRUE(GetMessage(Msg, %NULL, 0, 0))
        IF ISFALSE(TranslateAccelerator(ghWnd, ghAccel, Msg)) THEN
            TranslateMessage Msg
            DispatchMessage Msg
        END IF
    WEND
     
        FUNCTION = Msg.wParam
    END FUNCTION
    HTH
    Regards, Jules
    Best regards
    Jules
    www.rpmarchildon.com

    Comment


    • #3
      Or... change the shortcut settings..


      ------------------

      Comment

      Working...
      X