Search
Module:
Directory

   Desktop Functions:

   Smart Device Functions:


Show Recent Changes
Subscribe (RSS)
Misc. Pages
Comments
FAQ
Helpful Tools
Playground
Suggested Reading
Website TODO List
Download Visual Studio Add-In

DeferWindowPos (user32)
 
.
Summary

C# Signature:

[DllImport("user32.dll")]
static extern IntPtr DeferWindowPos(IntPtr hWinPosInfo, IntPtr hWnd,
   IntPtr hWndInsertAfter, int x, int y, int cx, int cy, uint uFlags);

User-Defined Types:

DeferWindowPosCommands

C#

VB.NET

Public Enum ShowWindowCommands As UInteger
    '''<Summary>Draws a frame (defined in the window's class description) around the window.</Summary>
    SWP_DRAWFRAME = &H0020

    '''<Summary>Sends a WM_NCCALCSIZE message to the window, even if the window's size is not being changed. If this flag is not specified, WM_NCCALCSIZE is sent only when the window's size is being changed.</Summary>
    SWP_FRAMECHANGED = &H0020

    '''<Summary>Hides the window.</Summary>
    SWP_HIDEWINDOW = &H0080

    '''<Summary>Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter).</Summary>
    SWP_NOACTIVATE = &H0010

    '''<Summary>Discards the entire contents of the client area. If this flag is not specified, the valid contents of the client area are saved and copied back into the client area after the window is sized or repositioned.</Summary>
    SWP_NOCOPYBITS = &H0100

    '''<Summary>Retains the current position (ignores the x and y parameters).</Summary>
    SWP_NOMOVE = &H0002

    '''<Summary>Does not change the owner window's position in the Z order.</Summary>
    SWP_NOOWNERZORDER = &H0200

    '''<Summary>Does not redraw changes. If this flag is set, no repainting of any kind occurs. This applies to the client area, the nonclient area (including the title bar and scroll bars), and any part of the parent window uncovered as a result of the window being moved. When this flag is set, the application must explicitly invalidate or redraw any parts of the window and parent window that need redrawing.</Summary>
    SWP_NOREDRAW = &H0008

    '''<Summary>Same as the SWP_NOOWNERZORDER flag.</Summary>
    SWP_NOREPOSITION = &H0200

    '''<Summary>Prevents the window from receiving the WM_WINDOWPOSCHANGING message.</Summary>
    SWP_NOSENDCHANGING = &H0400

    '''<Summary>Retains the current size (ignores the cx and cy parameters).</Summary>
    SWP_NOSIZE = &H0001

    '''<Summary>Retains the current Z order (ignores the hWndInsertAfter parameter).</Summary>
    SWP_NOZORDER = &H0004

    '''<Summary>Displays the window.</Summary>
    SWP_SHOWWINDOW = &H0040
End Enum

Notes:

None.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Alternative Managed API:

Do you know one? Please contribute it!

Documentation

Please edit this page!

Do you have...

  • helpful tips or sample code to share for using this API in managed code?
  • corrections to the existing content?
  • variations of the signature you want to share?
  • additional languages you want to include?

Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).

 
Access PInvoke.net directly from VS:
Terms of Use
Find References
Show Printable Version
Revisions