Class FileHelper
- Namespace
- NuvTools.Storage
- Assembly
- NuvTools.Storage.dll
Provides helper methods for file name manipulation and sanitization.
public static class FileHelper
- Inheritance
-
FileHelper
- Inherited Members
Methods
GetFileName(string)
Sanitizes and extracts a valid file name from the provided string. Removes quotes, replaces ampersands with "and", and extracts the file name from a full path.
public static string GetFileName(string name)
Parameters
namestringThe file name or path to sanitize.
Returns
- string
A sanitized file name. Returns "NoName" if the input is null, empty, or whitespace.