Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
esalvaJSAU5
302 Views, 3 Replies

BrowserPane.Control is throwing an exception in .Net8 Addin

I created a custom addin project, This addin has a Test button in the ribbon.

 

The button click event will add a new BrowserPane to the active document. Im using AddByManifest to load the un managed active x control. 

 

During the execution of AddByManifest() the temporary MessageBox in the FormLoad event will shown, which makes me think that the control is loaded properly.

 

But when i try to access the BrowsePane.Control property, It is throwing an exception.


Does anyone have an idea on how to fix this problem ? 

I attached the CustomAddin that i created.

 

Thank you

 

esalvaJSAU5_0-1725946590809.png

 

Labels (4)

I looked into your code and I don't understand why you need to use BrowserPane when the requested content is derived from Windows.Forms.UserControl.

Isn't it better to use DockableWindow? C# sample is available for example here on my GitHub

Method BrowserPanes.AddByManifest is designed for placing ActiveX objects which is not your case in my opinion.

esalvaJSAU5
in reply to: esalvaJSAU5

.

Thanks for your reply. It works now. Thank you so much.