Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 85
Default HELP! - Closing form

K,
The following example was posted in the news group in March. (Try Google
Search on the newsgroup - great for getting past knowledge).

Private Sub UserForm_QueryClose(Cancel As Integer, Closemode As Integer)
If Closemode = vbFormControlMenu Then
MsgBox "Please Click The Exit Button To Close The File."
Cancel = True
End If
End Sub

Regards,
AlexJ


"Katie" wrote in message
...
I have a few forms in Excel that I do not want the user to be able to

close
without going through the questions asked on the form. As I have it

running
now, a user can click the "x" in the top right hand corner and the form

will
close. How do I disable this? thank you! I am frustrated - this is the

last
thing I need to figure out and I am sure it is so easy, but I can NOT

figure
it out! Thank you!



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default HELP! - Closing form

Thank you it worked!!

"Alex J" wrote:

K,
The following example was posted in the news group in March. (Try Google
Search on the newsgroup - great for getting past knowledge).

Private Sub UserForm_QueryClose(Cancel As Integer, Closemode As Integer)
If Closemode = vbFormControlMenu Then
MsgBox "Please Click The Exit Button To Close The File."
Cancel = True
End If
End Sub

Regards,
AlexJ


"Katie" wrote in message
...
I have a few forms in Excel that I do not want the user to be able to

close
without going through the questions asked on the form. As I have it

running
now, a user can click the "x" in the top right hand corner and the form

will
close. How do I disable this? thank you! I am frustrated - this is the

last
thing I need to figure out and I am sure it is so easy, but I can NOT

figure
it out! Thank you!




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cant get a combo box to update without closing form justin Excel Discussion (Misc queries) 0 May 17th 06 09:06 PM
Closing a Form Mike Excel Discussion (Misc queries) 2 March 14th 06 01:09 PM
HELP! - Closing form Norman Jones Excel Programming 0 September 16th 04 03:21 AM
closing form w/ Maco jeffP Excel Programming 4 June 19th 04 10:29 PM
need form to initialize without closing bruce forster Excel Programming 2 April 21st 04 11:57 PM


All times are GMT +1. The time now is 03:15 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"