方法1、使用模板导出,不要设置条件即可:
http://www.foxtable.com/webhelp/topics/0201.htm2、使用代码筛选掉不需要的行,比如
With Tables("订单")
Dim ids As String
For i as Integer = .TopPosition To .BottomPosition
.Rows(i).Locked = True
ids = ids & ",'" & .Rows(i)("订单编号") & "'"
Next
ids= ids.Trim(",")
.filter = "订单编号 In (" & ids & ")"
.SaveExcel("C:\data\test.xls","订单")
End With
[此贴子已经被作者于2024/4/14 20:39:05编辑过]