Deletes an existing User from the Data Store

Namespace: DotNetNuke.Entities.Users
Assembly: DotNetNuke (in DotNetNuke.dll)

Syntax

C#
public static bool DeleteUser(
	ref UserInfo user,
	bool notify,
	bool deleteAdmin
)
Visual Basic
Public Shared Function DeleteUser ( 
	ByRef user As UserInfo,
	notify As Boolean,
	deleteAdmin As Boolean
) As Boolean

Parameters

user
Type: DotNetNuke.Entities.Users..::..UserInfo%
The userInfo object to delete from the Database
notify
Type: System..::..Boolean
A flag that indicates whether an email notification should be sent
deleteAdmin
Type: System..::..Boolean
A flag that indicates whether the Portal Administrator should be deleted

Return Value

A Boolean value that indicates whether the User was successfully deleted

Remarks