Sub SetKeyboardRepeatInfo(ByVal Delay As Long, ByVal Speed As Long, _ Optional ByVal MakePermanent As Boolean) Dim flags As Long
If MakePermanent Then flags = SPIF_SENDWININICHANGE Or SPIF_UPDATEINIFILE End If SystemParametersInfo SPI_SETKEYBOARDDELAY, Delay, ByVal 0&, flags SystemParametersInfo SPI_SETKEYBOARDSPEED, Speed, ByVal 0&, flags End Sub |