LASTINPUTINFO (Structures)
Last changed: dreijer-75.73.43.6

.
Summary
The LASTINPUTINFO structure contains the time of the last input.

C# Signature:

    [StructLayout( LayoutKind.Sequential )]
    struct LASTINPUTINFO
    {
        public static readonly int SizeOf = Marshal.SizeOf(typeof(LASTINPUTINFO));

        [MarshalAs(UnmanagedType.U4)]
        public UInt32 cbSize;    
        [MarshalAs(UnmanagedType.U4)]
        public UInt32 dwTime;
    }

VB .NET Signature:

    <StructLayout(LayoutKind.Sequential)> _
    Structure LASTINPUTINFO
    <MarshalAs(UnmanagedType.U4)> _
    Public cbSize As Integer
    <MarshalAs(UnmanagedType.U4)> _
    Public dwTime As Integer
    End Structure

F# 4.1 Signature

   [<Struct; CLIMutable; StructLayout(LayoutKind.Sequential)>]
   type LastInputInfo = {
     size : int
     dwTime : uint32
   }

Notes:

dwTime does wrap around. Watch out for that, and beware of casting to a signed.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Alternative Managed API:

Do you know one? Please contribute it!

Documentation