Flicks FAQ: Userdelete


Back to the top of the FAQ

UserDelete

The UserDelete method deletes the specified user from the AuthentiX database and from all groups.

Syntax

UserDelete(userName)

Parameters

userName
Specifies the name of the user to delete.

Return Values

Returns 0 if the user is deleted, 1 if the user is not found

Example

The following example deletes the user PeterXX.

<% 
usingAuthentiXStandard = true
if (usingAuthentiXStandard) then
Set AuthX = Server.CreateObject("AUTHXOCX.AuthXOCXCtrl.1") 
else
Set AuthX = Server.CreateObject("AUTHXISP.AuthXOCXCtrl.1") 
protectedDomain = Request.ServerVariables("LOCAL_ADDR")
'protectedDomain = "hostheader.com"
AuthX.SetVirtualDomain protectedDomain, Request.ServerVariables("SCRIPT_NAME")
AuthX.SetVirtualDomainPassword("")
end if
%>
<% 
result = AuthX.UserDelete("PeterYY")
%>
<% If result = 0 Then %>
Successfully deleted
<% Else %>
Could not delete him
<% End If %>

 

Applies To

AuthentiX OCX Component

http://www.flicks.com/authentix/discover/main.htm

Back to the top of the FAQ