Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想将特定工作表或特定范围“另存为”pdf。
我尝试在我的代码中实现一个范围。
这是我一直在使用的:
ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _ "c:\Book1.pdf", Quality:= _ xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _ OpenAfterPublish:=True
你有代码,只需使用范围而不是activesheet
activesheet
例如Sheets("Sheet1").Range("B2:H28").ExportAsFixedFormat ...
Sheets("Sheet1").Range("B2:H28").ExportAsFixedFormat ...