Results 1 to 10 of 11

Thread: Left and Right Mouse Click Event

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Administrator Excel Fox's Avatar
    Join Date
    Mar 2011
    Posts
    1,401
    Rep Power
    10
    Why do you want to right-click? You can use a normal click, and the assigned macro will run even if the sheet is protected. And if you want the shapes also to be unprotected, then use

    Code:
    Sheet1.Protect UserInterfaceOnly:=True, Password:="xyz", DrawingObjects:=False
    A dream is not something you see when you are asleep, but something you strive for when you are awake.

    It's usually a bad idea to say that something can't be done.

    The difference between dream and aim, is that one requires soundless sleep to see and the other requires sleepless efforts to achieve

    Join us at Facebook

  2. #2
    Senior Member
    Join Date
    Oct 2011
    Posts
    135
    Rep Power
    15
    Hallo
    Still to solve the problems of selection wonder how the subject should be written the following code:
    Code:
    Sub Test()
        ActiveSheet.Shapes("Picture 309").Select        'I select the object
        ActiveSheet.Shapes("Picture 309").Deselect      'Here I would like to deselect the object
    End Sub
    Obviously, the code does not work ...

Similar Threads

  1. Set Adjust A Button Top Left Position Programmatically
    By jeffrey159 in forum Access Help
    Replies: 5
    Last Post: 02-02-2013, 06:24 PM
  2. Sort data sheet by right_click of mouse
    By Rasm in forum Excel and VBA Tips and Tricks
    Replies: 3
    Last Post: 12-08-2012, 07:34 PM
  3. Replies: 2
    Last Post: 02-29-2012, 08:24 PM
  4. Replies: 3
    Last Post: 12-07-2011, 09:59 PM
  5. Replies: 2
    Last Post: 11-08-2011, 08:52 AM

Posting Permissions

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