SoFunction
Updated on 2025-04-06

c# file name/path processing method example


string filePath = @"E:\Randy0528\Chinese Directory\";

("File Path:"+filePath);

("<br/>Change the extension of the path string.<br/>");

            ((filePath, "txt"));

("<br/>Returns directory information of the specified path string..<br/>");

            ((filePath));

("<br/>Returns the extension of the specified path string.<br/>");

            ((filePath));

("<br/>Returns the file name and extension of the specified path string.<br/>");

            ((filePath));

("<br/>Returns the file name of the specified path string without an extension.<br/>");

            ((filePath));

("<br/>Get root directory information for the specified path.<br/>");

            ((filePath));

("<br/>Returns a random folder name or file name.<br/>");

            (());

("<br/>Create a temporary file with uniquely named zero-bytes on disk and return the full path to the file.<br/>");

            (());

("<br/>Return the path to the temporary folder of the current system.<br/>");

            (());

("<br/>Determines whether the path includes a file extension.<br/>");

            ((filePath));

("<br/>Get a value indicating whether the specified path string contains absolute path information or relative path information.<br/>");

            ((filePath));