Fail to continue develop Inventor Add-In with Visual Studio 2022 (revert to VS 2019?)

Fail to continue develop Inventor Add-In with Visual Studio 2022 (revert to VS 2019?)

Maxim-CADman77
Advisor Advisor
2,746 Views
21 Replies
Message 1 of 22

Fail to continue develop Inventor Add-In with Visual Studio 2022 (revert to VS 2019?)

Maxim-CADman77
Advisor
Advisor

(this thread is consequent to this)

 

Recently I've bought a new PC and decided to use most recent Visual Studio 2022 Community instead of VS 2019 Community I have on my old PC ... BUT

When I tried to compile the code of my add-in on my new PC it failed reporting error BC31424 on all mentions of "stdole.IPictureDisp" (ribbon button images).

 

I then decided to add Microsoft.VisualStudio.Interop.DLL references of the project*.

This solved compile issue but Add-In button than failed to load into Inventor's ribbon with catch-Message:
"Method not found: 'Void Inventor.ButtonDefinitionObject.set_StandardIcon(stdole.IPictureDisp)'."

 

I'm a bit puzzled. Initial project code keep compile successfully in VS 2019.

 

What I'm missing?

 

*
I've found such recommendation for Excel Add-In developers - New version requiring Microsoft.VisualStudio.Interop.dll 

Please vote for Inventor-Idea Text Search within Option Names

0 Likes
Accepted solutions (1)
2,747 Views
21 Replies
Replies (21)
Message 21 of 22

Frederick_Law
Mentor
Mentor

I thought I've seen you here before.

 

I was using the same class for a while and changed to another one using "InventorButton.vb".

Don't remember where I got it from.

0 Likes
Message 22 of 22

Maxim-CADman77
Advisor
Advisor

An off-topic question:
How do I prevent generation of .xml (something to-do with resources?) file in Debug folder of my project (see mentioned in message #13 of this thread)?

 

UPDATE:
Nevermind. This is due to "Generate XML documentation file" checkbox  at Compile Project properties.

Please vote for Inventor-Idea Text Search within Option Names

0 Likes