以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 代码哪里错了? (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=132872) |
-- 作者:sloyy -- 发布时间:2019/4/1 9:35:00 -- 代码哪里错了? Dim Book As New XLS.Book(ProjectPath & "Attachments\\非住宅房租催缴通知模板.xls") Dim fl As String = ProjectPath & "Attachments\\房租催缴通知.xls" Book.Marks.Add("DWDZ",e.Form.Controls("Label2").TEXT) Book.Marks.Add("LXDH",e.Form.Controls("Label3").TEXT) Book.Marks.Add("DWMC",e.Form.Controls("Label4").TEXT) Book.Build() \'生成细节区 Book.Save(fl) \'保存工作簿 Dim App As New MSExcel.Application App.Visible = False Dim Wb As MSExcel.WorkBook = App.WorkBooks.Open(fl) Dim Ws As MSExcel.WorkSheet = Wb.WorkSheets(1) Ws.PrintOut Wb.Close App.Quit 我想批量直接打印,结果才打第一个就跳出提示: 如果打印1千个.... 这段代码哪里有问题?
|
-- 作者:有点甜 -- 发布时间:2019/4/1 12:56:00 -- wb.saved = true app.DisplayAlerts = false |