IDirectInputJoyConfig8::SetUserValues method (dinputd.h)
The IDirectInputJoyConfig8::SetUserValues method sets the user settings for the joystick.
Syntax
HRESULT SetUserValues(
LPCDIJOYUSERVALUES unnamedParam1,
DWORD unnamedParam2
);
Parameters
unnamedParam1
Points to a structure that receives information about the new user joystick settings.
unnamedParam2
Specifies the parts of the DIJOYUSERVALUES structure that contain values to be set. There may be zero, one, or more of the following:
DIJU_USERVALUES
Indicates that the user configuration settings (the ruv member of the DIJOYUSERVALUES structure) is valid.
DIJU_GLOBALDRIVER
Indicates that the global port driver (the wszGlobalDriver member of the DIJOYUSERVALUES structure) is valid.
A list of valid global drivers can be obtained by enumerating the list of joystick types. If the joystick type has the JOY_HWS_ISGAMEPORTDRIVER flag set in the dwFlags member of the JOYHWSETTINGS structure, then the wszCallout member of the DIJOYTYPEINFO structure contains the name of a driver that can be used as a global driver.
DIJU_GAMEPORTEMULATOR
Unused.
Return value
Returns DI_OK if successful; otherwise, returns one of the following COM error values:
Return code | Description |
---|---|
|
Joystick configuration has not been acquired. You must call IDirectInputJoyConfig8::Acquire before you can notify applications and drivers of changes to joystick configuration. |
|
One or more parameters was invalid. |
Requirements
Requirement | Value |
---|---|
Target Platform | Desktop |
Header | dinputd.h (include Dinputd.h) |