DevicePolicyManager.SetOrganizationColor(ComponentName, Color) Method

Definition

Called by a profile owner of a managed profile to set the color used for customization.

[Android.Runtime.Register("setOrganizationColor", "(Landroid/content/ComponentName;I)V", "GetSetOrganizationColor_Landroid_content_ComponentName_IHandler", ApiSince=24)]
public virtual void SetOrganizationColor (Android.Content.ComponentName admin, Android.Graphics.Color color);
[<Android.Runtime.Register("setOrganizationColor", "(Landroid/content/ComponentName;I)V", "GetSetOrganizationColor_Landroid_content_ComponentName_IHandler", ApiSince=24)>]
abstract member SetOrganizationColor : Android.Content.ComponentName * Android.Graphics.Color -> unit
override this.SetOrganizationColor : Android.Content.ComponentName * Android.Graphics.Color -> unit

Parameters

admin
ComponentName

Which DeviceAdminReceiver this request is associated with.

color
Color

The 24bit (0xRRGGBB) representation of the color to be used.

Attributes

Remarks

Called by a profile owner of a managed profile to set the color used for customization. This color is used as background color of the confirm credentials screen for that user. The default color is teal (#00796B).

The confirm credentials screen can be created using android.app.KeyguardManager#createConfirmDeviceCredentialIntent.

Starting from Android R, the organization color will no longer be used as the background color of the confirm credentials screen.

This member is deprecated. From android.os.Build.VERSION_CODES#R, the organization color is never used as the background color of the confirm credentials screen.

Java documentation for android.app.admin.DevicePolicyManager.setOrganizationColor(android.content.ComponentName, int).

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