Given a string \"filename.conf\", how to I verify the extension part?
\"filename.conf\"
I need a cross platform solution.
A NET/CLI version using System::String
System::String^ GetFileExtension(System::String^ FileName) { int Ext=FileName->LastIndexOf('.'); if( Ext != -1 ) return FileName->Substring(Ext+1); return ""; }