Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

bruinsrme

macrumors 604
Original poster
Oct 26, 2008
7,205
3,068
Hello my fellow mac programmers
I am not a programmer on either windows or mac.

the best I am is a windows guy able piece together some basic macros.

A presentation I built has a macro that sends me an email and closes powerpoint when a control button is pressed. Very simple. However, windows coding doesn't work with mac. I have a handful of users that are on mac.

Anyone feel like recompiling this windows macro to work on a mac?
Private Sub CommandButton1_Click()

Dim olApp As Object, olMail As Object
Set olApp = CreateObject("Outlook.Application")
Set olMail = olApp.CreateItem(0)
olMail.To = "someoneemail@mail.com"
olMail.Subject = "I have read & understand the use of "
olMail.Body = "I have read & understand the use of "

olMail.send

ActivePresentation.Close

End Sub

Many thanks in advance
 
None of the ActiveX/VBA based macro/coding stuff works on any of the Mac 'Microsoft Office' suite components (Excel, Word, PPT etc.).

One of my bugbears to be honest, limits what I can do at home vs. work when using excel.

Options?

1. If you want 100% compatibility with the M$/Windows/VBA equivalent then either move them to a PC or run VMWARE/PARALLELS with Windows and Office for windows (Costly... $400+?)

2. Use the OSX scripting language (Example: http://www.mactech.com/articles/mactech/Vol.21/21.09/ScriptingMail/index.html)

3. Accept you cant run the macros (My default setting...)
Regards
 
What do you mean? I use interchangeable spreadsheets with VBA and Macros all the time in Excel for Mac. In Excel 2016, the compatibility is much improved.

Edit: Ah- are you referring to the VBE and not VBA itself?

Edit #2: This is what I get for opening my mouth without looking. CRAP! Where did the developer environment go? We just upgraded to 2016 last week, and I did not go into the developer environments. It's all gone!!!
 
Last edited:
None of the ActiveX/VBA based macro/coding stuff works on any of the Mac 'Microsoft Office' suite components (Excel, Word, PPT etc.).

One of my bugbears to be honest, limits what I can do at home vs. work when using excel.

Options?

1. If you want 100% compatibility with the M$/Windows/VBA equivalent then either move them to a PC or run VMWARE/PARALLELS with Windows and Office for windows (Costly... $400+?)

2. Use the OSX scripting language (Example: http://www.mactech.com/articles/mactech/Vol.21/21.09/ScriptingMail/index.html)

3. Accept you cant run the macros (My default setting...)
Regards

Wow! I find that truly limiting.
On the windows side I put the control button and the windows users review the material, clicked the button and it sent me an email stating completion.
Shocked the mac side has such limitations.
This is very troublesome as my CEO has asked me to redo the corporate PowerPoint presentation. The executives all run on mac.
 
None of the ActiveX/VBA based macro/coding stuff works on any of the Mac 'Microsoft Office' suite components (Excel, Word, PPT etc.).

I use VBA in Excel 2016 for Mac daily. I have yet to run into compatibility issues between Mac and PC, but understand there are some methods not supported (my automation is not too complex).

In PPT, I do not see any way to create VBA code (no Dev tab as in Excel or Word). However, the Security & Privacy settings do allow you to Enable All Macros. So, it may be automation created on PC can in fact work on Mac, but don't expect all methods to work. For instance, the mail integration may not work on Mac (just speculating). Or, maybe the VBA editor launched from Excel or Word can be used to create PPT code?

Maybe your method could use an AppleScript handler to generate the email?

According to the following site, it appears MS intends to enhance VBA across all Mac Office apps in time:

https://dev.office.com/blogs/VBA-improvements-in-Office-2016
 
Last edited:
  • Like
Reactions: adib
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.