VB脚本代码
打印当前打开的excel工作表1
最佳答案
vbs脚本示例:
Dim MSEXCEL_FILENAME
Dim xlApp, WorkBooks, Sheet
MSEXCEL_FILENAME = "Excel文件路径"
Set xlApp = WSH.CreateObject("Excel.Application")
xlApp.Visible = False
Set WorkBooks = xlApp.Workbooks.Open(MSEXCEL_FILENAME)
Set Sheet = WorkBooks.Worksheets(1) ''打开第一个工作表
Sheet.PrintOut ''打印
Set Sheet = Nothing
WorkBooks.Close
Set WorkBooks = Nothing
xlApp.Quit
Set xlApp = Nothing
提问者对于答案的评价:
1
原创文章,作者:more0621,如若转载,请注明出处:https://www.zhaoplc.com/plc313015.html