Results 1 to 8 of 8

Command button text enlarges when print preview is exited

Threaded View

  1. #1
    Forum Contributor
    Join Date
    10-08-2013
    Location
    London
    MS-Off Ver
    365
    Posts
    136

    Command button text enlarges when print preview is exited

    Hi All,

    I have created a protected staff scheduling worksheet in Excel 2010 with over twenty command buttons and one toggle button, three of which are used to print different sections of the schedule.

    I can select one of the print command buttons, change print settings and print normally from the print preview and the worksheet will return to its normal state after selecting print. However, if I choose to exit the print preview without printing, via the close print preview button, upon returning to the work sheet all the text on every command button and the toggle button has been enlarged.

    All three print buttons use similar code:

    Private Sub CommandButton23_Click()
    'PRINT HOLIDAY/TOIL
        ActiveSheet.Unprotect
        Application.ScreenUpdating = False
        Range("A2:X34").Select
        Selection.PrintOut Preview:=True
        Range("E13").Select
        Application.ScreenUpdating = True
        ActiveSheet.Protect DrawingObjects:=False, Contents:=True, Scenarios:=True
    End Sub
    
    Private Sub CommandButton24_Click()
    'PRINT SCHEDULE
        ActiveSheet.Unprotect
        Application.ScreenUpdating = False
        ActiveSheet.Rows("13:34").Hidden = True
        Range("A2:X119").Select
        Selection.PrintOut Preview:=True
        ActiveSheet.Rows("13:34").Hidden = False
        Range("E13").Select
        Application.ScreenUpdating = True
        ActiveSheet.Protect DrawingObjects:=False, Contents:=True, Scenarios:=True
    End Sub
    
    Private Sub CommandButton25_Click()
    'PRINT EVENING SALES
        ActiveSheet.Unprotect
        Application.ScreenUpdating = False
        ActiveSheet.Rows("13:34").Hidden = True
        Range("A2:X160").Select
        Selection.PrintOut Preview:=True
        ActiveSheet.Rows("13:34").Hidden = False
        Range("E13").Select
        Application.ScreenUpdating = True
        ActiveSheet.Protect DrawingObjects:=False, Contents:=True, Scenarios:=True
    End Sub
    If I click the toggle button after the text has been enlarged, the text in some of the command buttons reverts back to normal but others remain in an enlarged text state. The only way all buttons appear to revert back to normal is if I select one of the print buttons again and then print instead of exiting the print preview.

    It is the command button text only not the button size that is effected. Does anyone have any idea what is causing this issue?

    Many thanks,
    Last edited by L plates; 12-13-2014 at 08:35 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Disable Print button in Full Print Preview
    By RaquelAR in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-17-2013, 02:03 PM
  2. VBA Macro shows Print Preview page: How to auto-maximize the Print Preview?
    By jonvanwyk in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-06-2010, 04:48 PM
  3. Why do Command Buttons get stacked after print preview?
    By thall22963 in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 04-05-2005, 04:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1