Results 1 to 5 of 5

Disabling the Windows "Close" Button (The BIG RED 'X')

Threaded View

  1. #1
    Forum Contributor
    Join Date
    09-14-2012
    Location
    Tucson, Arizona, USA
    MS-Off Ver
    Office 2010
    Posts
    105

    Disabling the Windows "Close" Button (The BIG RED 'X')

    I'm trying to figure out how to disable the Windows environment 'X', as that is a coworkers favorite way to close Excel he sometimes loses data because of it.

    I use the following coding to prevent 'improper' closure of UserForms

    Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
      If CloseMode = vbFormControlMenu Then
        Cancel = True
        MsgBox "Please use the 'Close' button!"
      End If
    End Sub
    I would like to know if there is a way to disable the 'X' that does not create a mess or cause issues in general? If it helps any, we are still using Windows XP Pro ver 2002 w/ SP3 with Office 2010, but we are slowly transitioning over to Win7 Pro, ours will be the LAST location about 6 months down the road.
    Last edited by LoneWolf3574; 10-27-2012 at 07:39 AM.

Thread Information

Users Browsing this Thread

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

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