What's on this page • • • • • • • • • • • • • If you click Page Break Preview button on tab 'View' and then click 'Normal' button, the lines appear, however, they don't disappear automatically. So how do you get rid of them? You can't easily disable them clicking a button on the ribbon, unfortunately, you must go to the Excel Options and disable it there. See detailed instructions below. I made a macro, demonstrated later in this article, that you can use to quickly disable the print preview lines, put it in your and use it whenever necessary. The is also a macro-enabled workbook for you to download further down in this post. It seems that if you close the workbook and then open it again the print preview lines disappear, however, this is in my opinion not recommended. How to remove dotted lines (Excel Options) • Click on tab 'File' on the ribbon. • Click on 'Options' • Click on tab 'Advanced'. • Scroll down to 'Display Options for this worksheet'. • Disable 'Show Page Breaks'. • Click 'OK' button. How to remove dotted lines (Immediate window) If you are familiar with the Immediate window in the Visual Basic Editor you can probably more quickly delete the print preview lines than through Excel Options. • Copy code below. • Press Alt+F11 to open the VB Editor. • Paste code to the Immediate window • Press Enter • Return to Excel ActiveSheet.DisplayPageBreaks = False How to remove print preview dotted lines [Excel 2007] • Click the Office button located at the top left side of your screen. • Click 'Excel Options'. Insert page breaks every x rows with Kutools for Excel. Java environment setup. In the popped out Insert Page Break Every Row prompt box, enter the interval number of rows which you want to insert the page break under the Interval of section, see screenshot: 3. Then click Ok button, the page breaks have been inserted into the current worksheet every 5 rows, see screenshot. Page Break on Value Change in Microsoft Excel. If you do the subtotal count (and you can even move the totals to a column outside the print area to get it out of printing with the rest of your data) and have your printing page setup set to 100% and off any type of ‘Fit to’ scaling, you should be able to get the automatic page breaking on Mac. • Click tab 'Advanced' in the left window. • Find 'Display Options for this Worksheet'. • Disable the check box 'Show Page Breaks' • Click 'OK' button. How to remove print preview dotted lines [Excel 2003] • Go to the Tools menu. • Click Options. • Click the View tab. • Disable checkbox Page Breaks found in Windows Options. • Click OK button. Excel 2011 Macintosh • Go to 'Preferences' on the menu. • Click View in 'Authoring'. • Disable checkbox 'Show Page Breaks' located below 'Windows Options' Build a macro and automate these steps If you often disable print preview lines manually why not build a macro that does it for you? It is not hard, simply copy the macro and paste it to your workbook module. If you want to use it any workbook you open, put it in a personal macro workbook and link it to the or the. In fact, you can save in your and become a lot more efficient in your work. Macro to disable print preview lines What happens if we record a macro while disabling 'Page Breaks' in Excel options? This is what the macro recorder returns: Macro1() ActiveSheet.DisplayPageBreaks = False End Sub Use the above line in the examples below if you don't want to toggle print preview lines. Macro toggles print preview lines on the active worksheet Using that code you can now show or hide 'Page Breaks' on the active sheet with a macro. Meaning, if 'Page Breaks' are visible this macro hides them. If 'Page Breaks' are hidden, the macro makes them visible. Sub Macro1() ActiveSheet.DisplayPageBreaks = Not ActiveSheet.DisplayPageBreaks End Sub Macro toggles print preview lines on every sheet in the workbook The following macro shows or hides 'Page Breaks' on every sheet in the current workbook. Sub Macro2() Dim sh As Worksheet For Each sh In ActiveWorkbook.Worksheets sh.DisplayPageBreaks = Not sh.DisplayPageBreaks Next sh End Sub Macro toggles print preview lines on every sheet in all open workbooks This macro toggles 'Page Breaks' on every sheet in every open workbook.
0 Comments
Leave a Reply. |