Error: VB Code for "ThisWorkbook" Mac version

YesConsulting

New Member
Joined
Jan 7, 2019
Messages
11
Office Version
365
Platform
Windows, MacOS
I wanted to extend the functionality of the doubleClick to all the sheets in a workbook, rather than having duplicating code in multiple worksheets.

1 So clicked on "ThisWorkbook" in VBA Project manager.
2 Got a Code Window.
3 Clicked on "Workbook" from the dropdown ((General)
4 Got an error
"Variable uses an Automation type not supported in Visual Basic


I am running v16.16.5 on a Mac OSX version 10.14 (latest)

Is my thinking correct? I was going to use the Sub "SheetBeforeDoubleClick" to do the work.
 
Last edited:

Some videos you may like

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

steve the fish

Well-known Member
Joined
Oct 20, 2009
Messages
8,053
Office Version
365
Platform
Windows
Looks like a problem with the mac. The syntax is:

Code:
Private Sub Workbook_SheetBeforeDoubleClick(ByVal Sh As Object, ByVal Target As Range, Cancel As Boolean)

End Sub
Try that and see how you get on.
 

Watch MrExcel Video

Forum statistics

Threads
1,095,203
Messages
5,443,009
Members
405,212
Latest member
Arnie58

This Week's Hot Topics

  • Copy entire row if CountA <>0 to another sheet
    [B]I want to copy entire row if CountA <>0 for column J7:AM7 (headers on J6:AM6) and so on till the last used cell is column D and paste the...
  • Select last used Row in Table
    I have created a Table in a Worksheet which is locked to prevent user errors and protect formula. Some of the cells require freetext entries which...
  • excel workbook: do not allow certain file name
    Hello all, Don't think this has ever been asked before, but how do I restrict file save [Before_Save Event] if the name of the file being saved...
  • fixing problem autofilter
    hello i need help about my code when i search by code in textbox it doesn't show anything this is my data [ATTACH type="full"...
  • “Weight”
    Hi, i’ve got a long sheet filled with weights such as kg,g,L & ml. i can build a formula to convert kg into g and liter into ml. How ever, my...
  • How to capitalize everything before a certain character?
    In column A, I have some text: Hello good day.mp3 Hello good day.flac etc. I'd like to capitalize everything before the period. I don't need the...
Top