newFilePath.LastIndexOf( " / " ) + 1 ); if (! Directory.Exi
Aspose.Cells Excel转成pdf
/// <summary> /// excel转pdf /// </summary> /// <param>文件地点</param> /// <param>转换后的文件地点</param> /// <returns></returns> public static void ExcelToPdf(string path, string newFilePath) { var dir = newFilePath.Substring(0, newFilePath.LastIndexOf("/") + 1); if (!Directory.Exists(dir)) { Directory.CreateDirectory(dir); } Aspose.Cells.Workbook excel = new Aspose.Cells.Workbook(path); excel.Save(newFilePath, Aspose.Cells.SaveFormat.Pdf); }
,温馨提示: 本文由Jm博客推荐,转载请保留链接: https://www.jmwww.net/file/web/32559.html