Udostępnij za pośrednictwem


DevicePolicyManager.SetProfileName(ComponentName, String) Method

Definition

Sets the name of the profile.

[Android.Runtime.Register("setProfileName", "(Landroid/content/ComponentName;Ljava/lang/String;)V", "GetSetProfileName_Landroid_content_ComponentName_Ljava_lang_String_Handler")]
public virtual void SetProfileName (Android.Content.ComponentName admin, string? profileName);
[<Android.Runtime.Register("setProfileName", "(Landroid/content/ComponentName;Ljava/lang/String;)V", "GetSetProfileName_Landroid_content_ComponentName_Ljava_lang_String_Handler")>]
abstract member SetProfileName : Android.Content.ComponentName * string -> unit
override this.SetProfileName : Android.Content.ComponentName * string -> unit

Parameters

admin
ComponentName

Which DeviceAdminReceiver this request is associate with.

profileName
String

The name of the profile. If the name is longer than 200 characters it will be truncated.

Attributes

Remarks

Sets the name of the profile. In the device owner case it sets the name of the user which it is called from. Only a profile owner or device owner can call this. If this is never called by the profile or device owner, the name will be set to default values.

Java documentation for android.app.admin.DevicePolicyManager.setProfileName(android.content.ComponentName, 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

See also