Share via


UserManager.SetRestrictionsChallenge(String) Method

Definition

Sets a new challenge PIN for restrictions.

[Android.Runtime.Register("setRestrictionsChallenge", "(Ljava/lang/String;)Z", "GetSetRestrictionsChallenge_Ljava_lang_String_Handler")]
public virtual bool SetRestrictionsChallenge (string? newPin);
[<Android.Runtime.Register("setRestrictionsChallenge", "(Ljava/lang/String;)Z", "GetSetRestrictionsChallenge_Ljava_lang_String_Handler")>]
abstract member SetRestrictionsChallenge : string -> bool
override this.SetRestrictionsChallenge : string -> bool

Parameters

newPin
String

the PIN to use for challenge dialogs.

Returns

Returns true if the challenge PIN was set successfully.

Attributes

Remarks

Sets a new challenge PIN for restrictions. This is only for use by pre-installed apps and requires the MANAGE_USERS permission.

This member is deprecated. The restrictions PIN functionality is no longer provided by the system. This method is preserved for backwards compatibility reasons and always returns false.

Java documentation for android.os.UserManager.setRestrictionsChallenge(java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to