Version: 2019.1

Path.GetFileName(string)

Switch to Manual

Description

Returns the file name, including the extension if any, of the specified path string.

The return value consists of the characters after the last directory character in path. If the last character of path is a directory separator character, returns an empty string.