Determines whether a path contains a file name extension.
Namespace: Crestron.SimplSharp.CrestronIOAssembly: SimplSharpHelperInterface (in SimplSharpHelperInterface.dll) Version: 2.21.121
Syntaxpublic static bool HasExtension(
string path
)
Parameters
- path String
- Specified path to search for an extension.
Return Value
Booleantrue if the characters that follow the last directory separator (\\ or /) or volume separator (:)
in the path include a period (.) followed by one or more characters; otherwise, false.
Exceptions| Exception | Condition |
|---|
| ArgumentException | path contains one or more of the invalid characters defined in Crestron.SimplSharp.CrestronIO.Path.GetInvalidPathChars(). |
Version Information
.NET
Supported in: 6.0
.NET Compact Framework
Supported in: 3.5
See Also