SPUtility.IsLoginValid Method (SPGlobalAdmin, String)
Uses the specified global administration object to determine whether the specified user name is valid.
Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No
Syntax
'Declaration
<SubsetCallableExcludeMemberAttribute(SubsetCallableExcludeMemberType.UnsupportedSPType)> _
Public Shared Function IsLoginValid ( _
globalAdmin As SPGlobalAdmin, _
strLoginName As String _
) As Boolean
'Usage
Dim globalAdmin As SPGlobalAdmin
Dim strLoginName As String
Dim returnValue As Boolean
returnValue = SPUtility.IsLoginValid(globalAdmin, _
strLoginName)
[SubsetCallableExcludeMemberAttribute(SubsetCallableExcludeMemberType.UnsupportedSPType)]
public static bool IsLoginValid(
SPGlobalAdmin globalAdmin,
string strLoginName
)
Parameters
globalAdmin
Type: Microsoft.SharePoint.Administration.SPGlobalAdminA Microsoft.SharePoint.Administration.SPGlobalAdmin object that represents global administrative settings for the server or server farm.
strLoginName
Type: System.StringA string that contains the user name.
Return Value
Type: System.Boolean
If true, the user name is valid; otherwise, false.