如何以编程方式检索Excel工作表中的页数?

Joh*_*ith 2 .net c# excel worksheet excel-interop

我不是在寻找工作表的数量.我正在寻找每个工作表中的总页数.

S3d*_*di9 5

这就是你如何得到它

ActiveSheet.PageSetup.Pages.Count
Run Code Online (Sandbox Code Playgroud)

  • http://stackoverflow.com/questions/3751468/get-number-of-pages-for-printing-from-excel-interopb @John Smith (2认同)