- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
I recently upgraded to 2022 cad from 2019. I have the following lines that I run to unload the Vault Add-in before subroutines to avoid all the vault "Do you want to check this out" prompts for each file, and then reload afterward.
Sub VaultAddIn()
Dim strResponse As String
strResponse = MsgBox("Yes=Load, No=Unload, Cancel=Do Nothing", vbYesNoCancel, "Do you want to load/unload Vault Add In?")
Select Case strResponse
Case vbYes
ThisApplication.ApplicationAddIns.ItemById("{48B682BC-42E6-4953-84C5-3D253B52E77B}").Activate
Case vbNo
ThisApplication.ApplicationAddIns.ItemById("{48B682BC-42E6-4953-84C5-3D253B52E77B}").Deactivate
End Select
End Sub
When the .Activate line is run, I get the following error. I used to get this error in INV2019 about 10% of the time, but now in 2022 I get it every single time. I want to add that I get this error when I have an assembly opened. If I open Inventor and no file is open, I can unload/load the vault addin as much as I want through the API with no errors.
If I load/unload via the GUI from Tools->Add-Ins, the vault fails to load properly, again if an assembly is already opened. I can still check files in/out, but several ribbon buttons are missing from the Vault Tab. If I pull the GUI up again, it says the Vault Add-in is still unloaded. Below are some UI snips to display the odd behavior.
Vault Tab
Context Menu, Extra "Vault"
I noticed that the vault add-in is in the \ProgramData folder, while all the other add-ins are in \Program Files. Is this supposed to be here? Could the fact that this folder is Hidden be causing this problem? My user account has full admin privileges, and also running INV as admin makes no difference.
Any help with this would be greatly appreciated. Many thanks in advance.
Rafael
WIN10 x64 PRO, INV2022.1.1 PRO
Solved! Go to Solution.