Thanks Thanks:  0
Likes Likes:  0
Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: Userform Close Button

  1. #1
    Board Regular
    Join Date
    Mar 2002
    Posts
    79
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Is it possible to stop a user shutting a userform with the close button.

    Thx
    Roy

  2. #2
    Board Regular
    Join Date
    Feb 2002
    Location
    Where the wild roses grow
    Posts
    285
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Yeah, just take the code out and watch their confused little face

  3. #3
    Board Regular
    Join Date
    Mar 2002
    Posts
    79
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I want to disable the close button if it is possible.

    Thx
    Roy The Boy

  4. #4
    Board Regular
    Join Date
    Feb 2002
    Location
    Where the wild roses grow
    Posts
    285
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Do you want it to do something else instead, or just stay on the page and do nothing when it's pressed?

  5. #5
    Board Regular
    Join Date
    Mar 2002
    Posts
    79
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I want it to stay on the sheet and remain active and tell the user that they cannot close it down by pressing the close button

    Thx
    Roy alias Reg

  6. #6
    Board Regular
    Join Date
    Feb 2002
    Location
    Where the wild roses grow
    Posts
    285
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Mmmkay....

    The code you want is:

    Private Sub CommandButton1_Click()

    MsgBox ("You cannot close this form by pressing the close button")

    End Sub

  7. #7
    Board Regular
    Join Date
    Mar 2002
    Posts
    60
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hmmm.........

    Intreging!

    I must know, why would you want the user to be stuck on a page only getting told that they cant go anywhere?

    Dan.

  8. #8
    Board Regular
    Join Date
    Feb 2002
    Location
    Where the wild roses grow
    Posts
    285
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Are you into torture RoyInUK2000? I bet you've got a rack in your cellar...

  9. #9
    Board Regular
    Join Date
    Mar 2002
    Posts
    79
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    The user wouldn't get stuck. The userform has 8 commandbuttons on it which move them on, so basically they must press one of the command buttons and not the close button. I only want to stop a user pressing the close button ( The cross in the corner ). Any other command button is fine

    Come on someone out there must know the answer

    Thax
    Roy

  10. #10
    Board Regular
    Join Date
    Feb 2002
    Location
    Where the wild roses grow
    Posts
    285
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Oh THAT close button!! I thought you meant you'd drawn one on there and didn't want people pressing it. I thought that was a bit strange....

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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