# SetKeyboardPreferences

int SetKeyboardPreferences (unsigned long repeatDelay, unsigned long speed);

## Purpose

This function sets the timing attributes of the currently installed Windows keyboard.

## Parameters

Input
Name | Type | Description
repeatDelay | unsigned long | This parameter specifies the keyboard repeat delay (0–3 increasing).
speed | unsigned long | This parameter specifies the keyboard speed (0–31 increasing).

## Return Value

Name | Type | Description
status | integer | The status code that the function returns. 0 indicates success. A negative value indicates an error. This function may return a Programmer's Toolbox or UI Library error code. Call GetGeneralErrorString to obtain a text description of the error.