I just started creating a simple add-in application in VB .net for Revit 2019 by following the tutorial:
https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/CloudHelp/cloudhelp/2014/EN... (from Apr 18 2014).
I have completed all steps successfully, however, my add-in application doesn't appear on addins>external tools.
I took a look at:
https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/simplecontent/content/my-fi...
only to realize it's for C# and cannot help me.
Here I found possible reasons to why this may be hapening:
http://help.autodesk.com/view/RVT/2017/ENU/?guid=GUID-8EB25D2A-3CAF-486A-BA8E-C2BEF3DB68F6
"However, in some cases, an add-in application may fail to load without any message. Possible causes include:
I still don't understand what might be the problem. I tried to check all 3:
Any help would be appretiated.
Revit Version: Full Version of Autodesk Revit 2019
Windows version: 10 Pro
Processor: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz
RAM: 32GB
Solved! Go to Solution.
I just started creating a simple add-in application in VB .net for Revit 2019 by following the tutorial:
https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/CloudHelp/cloudhelp/2014/EN... (from Apr 18 2014).
I have completed all steps successfully, however, my add-in application doesn't appear on addins>external tools.
I took a look at:
https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/simplecontent/content/my-fi...
only to realize it's for C# and cannot help me.
Here I found possible reasons to why this may be hapening:
http://help.autodesk.com/view/RVT/2017/ENU/?guid=GUID-8EB25D2A-3CAF-486A-BA8E-C2BEF3DB68F6
"However, in some cases, an add-in application may fail to load without any message. Possible causes include:
I still don't understand what might be the problem. I tried to check all 3:
Any help would be appretiated.
Revit Version: Full Version of Autodesk Revit 2019
Windows version: 10 Pro
Processor: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz
RAM: 32GB
Solved! Go to Solution.
Solved by stever66. Go to Solution.
Solved by stever66. Go to Solution.
There are so many things that could be wrong. Its hard to tell without seeing your manifest file.
But if revit tries to load the addin, you should get a message when revit first starts the first time that addin is loaded that says something like "Do you want to load add-in XX? Always? Once?"
If you haven't got that, Revit probably isn't reading the manifest file. Make sure the file extension is HelloWorld.addin, and not HelloWorld.addin.txt, or something like that.
Also, did you try starting the program in a de-bugging mode like they show? Did that work?
There are so many things that could be wrong. Its hard to tell without seeing your manifest file.
But if revit tries to load the addin, you should get a message when revit first starts the first time that addin is loaded that says something like "Do you want to load add-in XX? Always? Once?"
If you haven't got that, Revit probably isn't reading the manifest file. Make sure the file extension is HelloWorld.addin, and not HelloWorld.addin.txt, or something like that.
Also, did you try starting the program in a de-bugging mode like they show? Did that work?
In the attached file (Hello World.png) you can see the manifest file.
When oppening Revit I do not get any mesage about the loading of the plugin.
I have only tried debug mode, the addin does not appear on the external tools.
The addin is saved correctly and not as an addin.txt
In the attached file (Hello World.png) you can see the manifest file.
When oppening Revit I do not get any mesage about the loading of the plugin.
I have only tried debug mode, the addin does not appear on the external tools.
The addin is saved correctly and not as an addin.txt
It's working!
Thank you for your help.
It's working!
Thank you for your help.
However I'm still getting an error: It fails to load the .dll (see attached file).
The Full Class Name is wrong. I don't know what to write them. My Class name is HelloWorld, so I wrote that the FullClassName is HelloWorld. What am I missing?
However I'm still getting an error: It fails to load the .dll (see attached file).
The Full Class Name is wrong. I don't know what to write them. My Class name is HelloWorld, so I wrote that the FullClassName is HelloWorld. What am I missing?
It also might not be finding the .dll file. Its often easier to copy the .dll file to the same folder as the addin, and then the <Assembly> line can just be:
<Assembly>./HelloWorld.dll</Assembly>
or even just
<Assembly>HelloWorld.dll</Assembly>
Of course, spelling and capitalization is critical here - any typos will cause a failure to load. Renaming the project after starting it sometimes also seems to be an issue. I don't know why they do that on a "my first plugin" tutorial. It seems to work better when I start a VS project with the right name. Changing the name sometimes seems to have some behind the scenes impact.
If there is a namespace in the add-in, you have to add that to the full class name (although I don't see one in the example, but I don't know much about VB.) So if you had a namespace HelloWorld and a class in that namespace also called HelloWorld, you would use:
<FullClassName>HelloWorld.HelloWorld</FullClassName>
That might be worth a try. I hope something here helps. If not, you might try starting from scratch, and just name the Project HelloWorld from the start.
It also might not be finding the .dll file. Its often easier to copy the .dll file to the same folder as the addin, and then the <Assembly> line can just be:
<Assembly>./HelloWorld.dll</Assembly>
or even just
<Assembly>HelloWorld.dll</Assembly>
Of course, spelling and capitalization is critical here - any typos will cause a failure to load. Renaming the project after starting it sometimes also seems to be an issue. I don't know why they do that on a "my first plugin" tutorial. It seems to work better when I start a VS project with the right name. Changing the name sometimes seems to have some behind the scenes impact.
If there is a namespace in the add-in, you have to add that to the full class name (although I don't see one in the example, but I don't know much about VB.) So if you had a namespace HelloWorld and a class in that namespace also called HelloWorld, you would use:
<FullClassName>HelloWorld.HelloWorld</FullClassName>
That might be worth a try. I hope something here helps. If not, you might try starting from scratch, and just name the Project HelloWorld from the start.
Thank you. I have checked the .dll's properties and it has not been flagged by windows. I have tried with a namespace, without a namespace, with a different class name, with the .dll in the same folder as the addin, and tried doing it all from scratch without renaming the .vb file. Unfortunately it still did not work. It keeps on showing this message, no matter what class name I write:
Failed to initialize the add-in "HelloWorld" because the class "HelloWorld" cannot be found in the add-in assembly.
The FullCassName provides the entry point for Revit to call the add.in application. For Revit to run the add-in, you must ensure this class implements the "Atuodesk. Revit.UI.IExternalCommand" interface.
I think the problem is that it is not finding the class in the assembly.
Thank you. I have checked the .dll's properties and it has not been flagged by windows. I have tried with a namespace, without a namespace, with a different class name, with the .dll in the same folder as the addin, and tried doing it all from scratch without renaming the .vb file. Unfortunately it still did not work. It keeps on showing this message, no matter what class name I write:
Failed to initialize the add-in "HelloWorld" because the class "HelloWorld" cannot be found in the add-in assembly.
The FullCassName provides the entry point for Revit to call the add.in application. For Revit to run the add-in, you must ensure this class implements the "Atuodesk. Revit.UI.IExternalCommand" interface.
I think the problem is that it is not finding the class in the assembly.
In visual studio there should be project settings. Make sure u are using .net 4.7 or 4.7.2 for revit 2019.
Also be sure the revit API and api up files from the revit 2019 folder? Make sure they are not from an older version.
Then find the .dll file and right click it and check the security settings. Make sure it's not disabled, although I have only seen this on files copied from another computer.
you still haven't said if you got the debugging part to work where visual studio starts revit when you start debugging. You might have to use the " managed compatibility " setting in visual studio to get that to work.
In visual studio there should be project settings. Make sure u are using .net 4.7 or 4.7.2 for revit 2019.
Also be sure the revit API and api up files from the revit 2019 folder? Make sure they are not from an older version.
Then find the .dll file and right click it and check the security settings. Make sure it's not disabled, although I have only seen this on files copied from another computer.
you still haven't said if you got the debugging part to work where visual studio starts revit when you start debugging. You might have to use the " managed compatibility " setting in visual studio to get that to work.
I just tried with both .net 4.7 and 4.7.2.
i'm using the right API files from Revit 2019.
.dll security settings are not disabled.
I can start the debugging process successfully andload the .dll. Only when executing the "HelloWorld" addin I still get that message :C
The issue is the Root Namespace in the properties of the project>application tab, which I was not aware of, and has to be included in the FullClassName.
Thank you @stever66!
I just tried with both .net 4.7 and 4.7.2.
i'm using the right API files from Revit 2019.
.dll security settings are not disabled.
I can start the debugging process successfully andload the .dll. Only when executing the "HelloWorld" addin I still get that message :C
The issue is the Root Namespace in the properties of the project>application tab, which I was not aware of, and has to be included in the FullClassName.
Thank you @stever66!
Can't find what you're looking for? Ask the community or share your knowledge.