Outlook Add-in loads in Outlook 2019 x64, but code does not run

Add-in Express™ Support Service
That's what is more important than anything else

Outlook Add-in loads in Outlook 2019 x64, but code does not run
The code does not run in the Outlook add-in 
Roberto Esguerra




Posts: 22
Joined: 2022-01-31
I have written in C# an Outlook Add-in for Outlook 2019 x64. It compiles with no errors. I've also created a setup project, and the entire solution, add-in and setup, builds without issue.

When I run the setup, it completes successfully. I have confirmed in the adxregistrator.log that the registration process completes with HRESULT=0.

However, I suspect that the code I've written doesn't actually run. I have a line in the AddinModule_AddinInitialize function that does a File.WriteAllText to a log file in C:\Temp. When I check that directory for that log file, after Outlook is finally ready, I don't see the log file that is supposed to be in C:\Temp. I can create other files in that directory without trouble.

If the AddinModule_AddinInitialize code isn't running, then all of my other code won't take effect.
Posted 14 Jun, 2022 19:00:49 Top
Roberto Esguerra




Posts: 22
Joined: 2022-01-31
Never mind, I resolved this. I don't know why, but the InitializeComponent() function did not have the following line:

blue

Once I added this line of code, my initialization code ran.
Posted 15 Jun, 2022 01:41:57 Top
Andrei Smolin


Add-in Express team


Posts: 18806
Joined: 2006-05-11
Hello Roberto,

Thank you for publishing the way you get the issue resolved!

Regards from Poland (CEST),

Andrei Smolin
Add-in Express Team Leader
Posted 15 Jun, 2022 02:19:22 Top