Share via


SPUrlUtility.IsLegalFileName method

Validates the specified URL leaf name.

Namespace:  Microsoft.SharePoint.Utilities
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Shared Function IsLegalFileName ( _
    name As String _
) As Boolean
'Usage
Dim name As String
Dim returnValue As Boolean

returnValue = SPUrlUtility.IsLegalFileName(name)
public static bool IsLegalFileName(
    string name
)

Parameters

Return value

Type: System.Boolean
Returns a Boolean value of true if the specified leaf name is valid; otherwise, this method returns false.

See also

Reference

SPUrlUtility class

SPUrlUtility members

Microsoft.SharePoint.Utilities namespace