Compartir a través de


UserManager<TUser>.SetUserNameAsync(TUser, String) Método

Definición

Establece el objeto especificado userName para el especificado user.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::IdentityResult ^> ^ SetUserNameAsync(TUser user, System::String ^ userName);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult> SetUserNameAsync (TUser user, string userName);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult> SetUserNameAsync (TUser user, string? userName);
abstract member SetUserNameAsync : 'User * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
override this.SetUserNameAsync : 'User * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
Public Overridable Function SetUserNameAsync (user As TUser, userName As String) As Task(Of IdentityResult)

Parámetros

user
TUser

Usuario cuyo nombre se debe establecer.

userName
String

Nombre de usuario que se va a establecer.

Devoluciones

El objeto Task que representa la operación asincrónica.

Se aplica a