place content in the center of pdf
2017-09-07 17:14
387 查看
Sub ConvertPDFCenter() Dim workPath workPath = ThisWorkbook.Path With ActiveSheet.PageSetup .LeftMargin = Application.InchesToPoints(0.708661417322835) .RightMargin = Application.InchesToPoints(0.708661417322835) .TopMargin = Application.InchesToPoints(0.748031496062992) .BottomMargin = Application.InchesToPoints(0.748031496062992) .HeaderMargin = Application.InchesToPoints(0.31496062992126) .FooterMargin = Application.InchesToPoints(0.31496062992126) .PrintHeadings = False .PrintGridlines = False .PrintComments = xlPrintNoComments .PrintQuality = 600 .CenterHorizontally = True .CenterVertically = False .Orientation = xlPortrait .Draft = False .PaperSize = xlPaperA4 .FirstPageNumber = xlAutomatic .Order = xlDownThenOver .BlackAndWhite = False .Zoom = 100 .PrintErrors = xlPrintErrorsDisplayed .OddAndEvenPagesHeaderFooter = False .DifferentFirstPageHeaderFooter = False .ScaleWithDocHeaderFooter = True .AlignMarginsHeaderFooter = True End With Range("A1:D16").ExportAsFixedFormat Type:=xlTypePDF, Filename:= _ workPath & "\t.pdf", Quality:= _ xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas:=False, _ OpenAfterPublish:=True End Sub
ActiveWindow.View = xlPageBreakPreview ActiveSheet.VPageBreaks(1).DragOff Direction:=xlToRight, RegionIndex:=1
相关文章推荐
- pyqt4 place window in the center of screen
- Get the content of an Iframe in Javascript – crossbrowser solution for both IE and Firefox
- Get the content of an Iframe in Javascript – crossbrowser solution for both IE and Firefox
- bpel 测试遇到“The content of the body cannot be displayed in the form view. Please switch to the source”
- A VS.NET add-in to know the content of the any dataset during debugging
- How to alignment the center position of the button in Android?
- Get the content of an Iframe in Javascript – crossbrowser solution for both IE and Firefox
- Get the content of an Iframe in Javascript – crossbrowser solution for both IE and Firefox
- fast reports V3.15 输出CJK PDF完美解决方案(the solution of exporting CJK PDF in fast reports)
- 3.1 Placing UI Components in the Center of the Screen
- How to get the content of the 'identity' section in web.config
- XML文件要有根标签(Extra content at the end of the document in file 错误)
- 苹果审核:2.12 We found that the usefulness of your app is limited by the minimal amount of content it in
- Check for the content of input in UI
- Warning: POST Content-Length of 81360713 bytes exceeds the limit of 3145728 bytes in Unknown on line
- print 'welcome to masm!' in the center of the screen.
- Get the content of an Iframe in Javascript – crossbrowser solution for both IE and Firefox
- The content of element type "package" must match "(result-types?,interceptors?,default-interceptor-ref?,default-action-ref?,default-class-ref?,global- results?,global-exception-mappings?,action*)".
- (NOT CLEAR)Question 40: In the declaration below, p is a pointer to an array of 5 int pointers:
- 关于Adapter的The content of the adapter has changed问题分析