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
Support Forum
Download Visual Studio Add-In

Terms of Use
Privacy Policy

Search Results for "SystemParametersInfo" in [All]

Enums

1: SPI
.
Summary
.

    /// SPI_ System-wide parameter - Used in SystemParametersInfo function

.

    [Description("SPI_(System-wide parameter - Used in SystemParametersInfo function )")]

.

      /// SystemParametersInfo fails.

.

      /// SystemParametersInfo fails.

.
Documentation
[SystemParametersInfo] on MSDN
2: SPIF
.
Summary
.

        /// To set the width of the double-click rectangle, call SystemParametersInfo with SPI_SETDOUBLECLKWIDTH.

.

        /// call the SystemParametersInfofunction with the SPI_GETWORKAREA value.

.

        /// rectangle, call SystemParametersInfo with SPI_SETDOUBLECLKHEIGHT.

.

        /// call the SystemParametersInfo function with the SPI_GETWORKAREA value.

.

    ''' Width of the client area for a full-screen window on the primary display monitor in pixels. To get the coordinates of the portion of the screen not obscured by the system taskbar or by application desktop toolbars call the SystemParametersInfo function with the SPI_GETWORKAREA value.

.

    ''' Height of the client area for a full-screen window on the primary display monitor in pixels. To get the coordinates of the portion of the screen not obscured by the system taskbar or by application desktop toolbars call the SystemParametersInfo function with the SPI_GETWORKAREA value.

.

    /// An application sends the WM_WININICHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI.

.

    /// An application sends the WM_WININICHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI.

.

    '''An application sends the WM_SETTINGCHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI.

.

    '''An application sends the WM_WININICHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI. Note The WM_WININICHANGE message is provided only for compatibility with earlier versions of the system. Applications should use the WM_SETTINGCHANGE message.

.

    ''' the SystemParametersInfo function changes a system-wide setting or when policy settings have changed.

Constants

5: WM
.
WM_SETTINGCHANGE 0x1A An application sends the WM_SETTINGCHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI.
.
WM_WININICHANGE 0x1A An application sends the WM_WININICHANGE message to all top-level windows after making a change to the WIN.INI file. The SystemParametersInfo function sends this message after an application uses the function to change a setting in WIN.INI. Note The WM_WININICHANGE message is provided only for compatibility with earlier versions of the system. Applications should use the WM_SETTINGCHANGE message.

Structures

.
Summary
ANIMATIONINFO - Used with SystemParametersInfo for SPI_GETANIMATION or SPI_SETANIMATION
.

    /// Used with SystemParametersInfo when SPI_GETANIMATION or SPI_SETANIMATION action is specified.

.
Summary
The MinimizedMetrics structure is used with SystemParametersInfo to set the properties of minimized windows when opening or closing a shell application (e.g. Windows Explorer).

coredll

.

To keep a device awake indefinitely, you can use SystemParametersInfo() (also in CoreDll) to query the three idle timeouts SPI_GETBATTERYIDLETIMEOUT, SPI_GETEXTERNALIDLETIMEOUT, and SPI_GETWAKEUPIDLETIMEOUT. Ignoring any values that are zero, use the minimum of these three values as your N, set a recurring timer to fire more often than every N seconds, and call SystemIdleTimerReset() every time it fires. When you're done with your critical operation, kill the timer, and the device will be able to sleep again. I tried this from C# and each idle-timeout value was 0, so I just called SystemIdleTimerReset() every 30 seconds during the critical operation.

user32

.

- The foreground lock time-out has expired (see SPI_GETFOREGROUNDLOCKTIMEOUT in SystemParametersInfo).

.

    ///     <item>The foreground lock time-out has expired (see SPI_GETFOREGROUNDLOCKTIMEOUT in SystemParametersInfo).</item>

.
Summary
.

static extern bool SystemParametersInfo(SPI uiAction, uint uiParam, ref T pvParam, SPIF fWinIni); // T = any type

.

static extern bool SystemParametersInfo(SPI uiAction, uint uiParam, IntPtr pvParam, SPIF fWinIni);

.

static extern bool SystemParametersInfo(uint uiAction, uint uiParam, String pvParam, SPIF fWinIni);

.

static extern bool SystemParametersInfo(uint uiAction, uint uiParam, StringBuilder pvParam, SPIF fWinIni);

.

static extern bool SystemParametersInfo(SPI uiAction, uint uiParam, ref ANIMATIONINFO pvParam, SPIF fWinIni);

.

    Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Integer, _

.

Public Shared Function SystemParametersInfo( _

.

    [DllImport("user32.dll", EntryPoint="SystemParametersInfo", SetLastError = true)]

.

    public static extern bool SystemParametersInfoGet(uint action, uint param, ref uint vparam,     uint init);

.

    [DllImport("user32.dll", EntryPoint="SystemParametersInfo", SetLastError = true)]

.

    public static extern bool SystemParametersInfoSet(uint action, uint param, uint vparam,     uint init);

.

    bool retVal = SystemParametersInfoGet(SPI_GETFOREGROUNDLOCKTIMEOUT, 0, ref timeout, 0);

.

    SystemParametersInfoSet(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, 0, 0);

.

    private static extern int SystemParametersInfo(int uAction,

.

    SystemParametersInfo(SPI_GETNONCLIENTMETRICS, 0, ref metrics, 0);

.

    private static extern Int32 SystemParametersInfo(UInt32 uiAction, UInt32 uiParam, String         pvParam, UInt32 fWinIni);

.

        SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, filename, SPIF_UPDATEINIFILE);

.

Public Shared Function SystemParametersInfo( _

.

intReturn = SystemParametersInfo(SPI.SetWallpaper, 0, strFile, SPIF.UpdateAndSend)

.

    static extern bool SystemParametersInfo(uint uiAction, uint uiParam, StringBuilder pvParam, SPIF fWinIni);

.

        if (!SystemParametersInfo(SPI_GETDESKWALLPAPER, (uint)sb.Capacity, sb, SPIF.None))

.

Return type of some native methods like SystemParametersInfo is bool. They should be marked by [System.Runtime.InteropServices.MarshalAsAttribute].

.

    public static extern bool SystemParametersInfo(SystemParametersInfoActions uAction, uint uParam, ref uint lpvParam, uint fuWinIni);

.

The [System.Windows.Forms.SystemInformation] managed class, which uses SystemParametersInfo internally, has many (but not all) static properties containing user information, system setup, and preferences.

.

Also, [System.Drawing.SystemFonts] contains all the font settings which can be returned by SystemParametersInfo.

.
Documentation
[SystemParametersInfo] on MSDN
.

[DllImport("user32.dll", EntryPoint = "SystemParametersInfo")]

.

public static extern bool SystemParametersInfo(uint uiAction, uint uiParam, ref uint pvParam, uint fWinIni);


 
Access PInvoke.net directly from VS: