任何人都有关于如何使用C#在.xls Excel电子表格中嵌入PDF文件的任何提示?
答案 0 :(得分:4)
对于那些需要答案的人来说,就是......
Application xlApp = new Application();
xlApp.DisplayAlerts = false;
Workbook book = xlApp.Workbooks.Open(@"C:\test5.xls", 2, false);
Worksheet sheet = book.Worksheets[1];
sheet.Shapes.AddOLEObject(Filename: @"C:\test.pdf", Height: 400, Width: 400);
book.Save();
....
....
....