.addin file

.addin file

mike
Enthusiast Enthusiast
1,217 Views
3 Replies
Message 1 of 4

.addin file

mike
Enthusiast
Enthusiast

I created a VB.net plugin dll.  When I run it in debug mode it works perfectly (after some effort).  Now I want to move it to production.  I built a dll and placed it in a shared directory on the network.  Then I created a .addin file following the proper procedures.  When I start Revit, I am informed that my dll does not exist.  I double checked the path.  I switched to administrator and ran revit and it worked!  I moved the .dll thinking that maybe the dorectory was not accessible somehow.  I also changed the Text and Description tags to see if those would chnage in the error dialog.  They did not.  It's like another, older version of the .addin file is being found instead of the one in c:\programdata\Autodesk\Revit\addins\2013.  None of the changes I am making are being recognized.  

Also, I still have the command from the "My first plugin" tutorial showing up even though there is no .addin file for it in the directory.  Weird.

 

-mjm

0 Likes
Accepted solutions (1)
1,218 Views
3 Replies
Replies (3)
Message 2 of 4

Anonymous
Not applicable
Accepted solution

When you say "switched to administrator" does that mean "Run as Administrator" or did you log out and log in with the administrator account?

 

If it is a different account, then you may have an old addin file in your user profile, but not in the administrator profile.

 

Check "C:\Users\windows_user\AppData\Roaming\Autodesk\REVIT\Addins\2013" for addin files.

0 Likes
Message 3 of 4

Joe.Ye
Alumni
Alumni

 

When deploy the Revit addin's dll in the network position, you need to change the config in the Revit.exe.config file, which is located in the same folder with Revit.exe. 

This is explained in this page. http://wikihelp.autodesk.com/Revit/enu/2012/Help/API_Dev_Guide/0000-API_Deve0/0001-Introduc1/0012-Ge...

 

For convenience, include the description here.

 

    • If your application assembly dll is on a network share instead of your local hard drive, you must modify Revit.exe.config to allow .NET assemblies outside your local machine to be loaded. In the "runtime" node in Revit.exe.config, add the element <loadFromRemoteSources enabled="true"/> " as shown below.
      <runtime>
      	<generatePublisherEvidence enabled="false" />
      	<loadFromRemoteSources enabled="true"/> 
      </runtime>


Joe Ye
Contractor
Developer Technical Services
Autodesk Developer Network
0 Likes
Message 4 of 4

mike
Enthusiast
Enthusiast

You are exactly right!  Both solutions were right on.  Thank you guys.  I did have an extra in my profile that I could not find.  And I also moved the .dll to the network during troubleshooting.  

 

-mjm

0 Likes