现有一个文件路径为: localFilePath=”C:UsersyhoodDesktop林业局考勤06.xlsx“
string directory = Path.GetDirectoryName(localFilePath);
//文件所在路径 C:UsersyhoodDesktop string filename = Path.GetFileNameWithoutExtension(localFilePath);
//文件名 林业局考勤06 string extension = Path.GetExtension(localFilePath);
//文件后缀 带点(.) .xlsx