Share via


IUpdateSession2::UserLocale property

Gets and sets the preferred locale for which update information is retrieved..

If you do not specify the locale, the default is the user locale that GetUserDefaultUILanguage returns. If the information is not available in a specified locale or in the user locale, Windows Update Agent (WUA) tries to retrieve the information from the default update locale.

This property is read/write.

Syntax

HRESULT put_UserLocale(
  [in]  LCID value
);

HRESULT get_UserLocale(
  [out] LCID *retval
);

Property value

The locale that you want WUA to use to retrieve locale-specific update information.

Error codes

Returns S_OK if successful. Otherwise, returns a COM or Windows error code.

Remarks

A search from an UpdateSearch object that was created from the UpdateSession object fails if the following conditions are true:

  • A user or a power user set the UserLocale property for the IUpdateSession2 interface to a locale.
  • The locale corresponds to a language that is not installed on the computer.

Requirements

Minimum supported client

Windows XP, Windows 2000 Professional with SP3 [desktop apps only]

Minimum supported server

Windows Server 2003, Windows 2000 Server with SP3 [desktop apps only]

Header

Wuapi.h

IDL

Wuapi.idl

Library

Wuguid.lib

DLL

Wuapi.dll

See also

IUpdateSession2