Can you count how many times a macro has been ran over multiple of the same file?

Bassie

Board Regular
Joined
Jan 13, 2022
Messages
66
Office Version
  1. 2019
Platform
  1. Windows
Hi,

So bit of a strange question, I created a macro that I distributed to 6 teams. Now to calculate impact of my macro I would like to add a feature in the newer versions that counts how many times the macro has been ran. However, every team will use their own version of the macro (so not the same file). Is this even possible? I was thinking about automatically sending an e-mail to me ones the macro has been ran but that sounds way over complicating the issue (they also don't work on the same shared drive, that was my first solution)

Regards,
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Is there any common network drive/share that everyone has access to?
If so, you can place an Excel file out there as a sort of a Log file, and have your Macro write to it everytime it runs.
It would simply open the file, add a new row with details of who ran it and when, then save and close the file.
 
Upvote 0
Is there any common network drive/share that everyone has access to?
If so, you can place an Excel file out there as a sort of a Log file, and have your Macro write to it everytime it runs.
It would simply open the file, add a new row with details of who ran it and when, then save and close the file.
Hi, Thanks for your reaction!

This is unfortunately not possible as the teams are part of different parts of the organization and thus have different shared drives.
 
Upvote 0
Only other way I could see is write to an INI file or a variable in the registry
 
Upvote 0
Only other way I could see is write to an INI file or a variable in the registry
Not sure I have the required knowledge at the moment to do this but I will look in to it thank you for the suggestions!
 
Upvote 0
Hi, Thanks for your reaction!

This is unfortunately not possible as the teams are part of different parts of the organization and thus have different shared drives.
You could have each write to some drive in their own environment (maybe log a single row text file for each run(, and then have something on company network server collect them every night and aggregate them into a single workbook.
 
Upvote 0

Forum statistics

Threads
1,215,590
Messages
6,125,707
Members
449,251
Latest member
Herushi

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top