My company has set the policy of not allowing macros by default. By my understanding, this just means that i can't import macro by default, however i can still run my code if i do Alt+F11 and paste codes inside ThisOutlookSession . I've successfully got all the code working, but after restarting my PC, manually pasting the code in ThisOutlookSession doesn't work anymore and the codes are already pasted in by default. Even doing MsgBox in the NewMailEx event doesn't work. I've googled around and the general consensus is that a workaround is to delete ThisOutlookSession in AppData. However i can't access AppData as well as enable all/some macros.
Is there any workaround, Eg. Can I access Outlook application through Excel and "intercept" NewMailEx Since I've determined that Excel works through the VBA even when restarted. All i have to do is copy and paste the code in again.
TL;DR: ThisOutlookSession doesn't work after I reset my PC. Unable to access AppData and modify Macro Settings. Seeking workaround for example, open Excel and getting mail from Outlook via VBA if possible?
Thanks for the help!