Foxtable(狐表)用户栏目专家坐堂 → 后台输出失败


  共有4892人关注过本帖树形打印复制链接

主题:后台输出失败

帅哥哟,离线,有人找我吗?
lihe60
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:狐神 帖子:6886 积分:43605 威望:0 精华:0 注册:2009/3/2 14:07:00
后台输出失败  发帖心情 Post By:2023/2/7 10:30:00 [显示全部帖子]

Dim filter As String
Dim Book As New XLS.Book(ProjectPath & "Attachments\销售合同.xls")
Dim Sheet As XLS.Sheet = Book.Sheets(0)
Sheet(6, 6).Value = "制单人:" & User.Name '修改模板,加入制单人信息
filter = "Sel\ect * from {表B} where [_identify]=2"
Dim fl As String = ProjectPath & "Reports\出库单.xls"
book.AddDataTable("表B", "", filter) '添加父表
filter = "Sel\ect * from {表C} where [_identify]=2"
book.AddDataTable("表C", "" , filter) '添加子表
book.AddRelation("表B", "[_identify]", "表C", "[_identify]") '建立关联
messagebox.show(4)
Book.Build() '生成细节区
Book.Save(fl) '保存工作簿
messagebox.show(5)
Dim Proc As New Process '打开工作簿
Proc.File = fl
Proc.Start()

 回到顶部