System.Web.VirtualPathUtility.AppendTrailingSlash Method

Appends the literal slash mark (/) to the end of the virtual path, if one does not already exist.

Syntax

public static string AppendTrailingSlash (string virtualPath)

Parameters

virtualPath
The virtual path to append the slash mark to.

Returns

The modified virtual path.

Remarks

If the literal slash mark (/) exists at the end of the virtual path, the virtual path is not modified.

Requirements

Namespace: System.Web
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0