How to use Deploy Rps Addin

75 views
Skip to first unread message

Hoss M

unread,
Jan 29, 2024, 8:47:19 AMJan 29
to RevitPythonShell
Hello,

I was wondering if there is a how to manual or even better a demo for how to use the Deploy Rps Addin?

Thanks for your help in advance

Callum

unread,
Jan 30, 2024, 2:24:13 PMJan 30
to RevitPythonShell
Hi Hoss, the first couple of hits in Google are your best bet Id say:

Screenshot 2024-01-31 082149.png

- The online book that they both link to are a wealth of information thats still relevant today
- Further down the list of Google results are real-world examples by multiple authors

Any further questions let us know!

Hoss M

unread,
Feb 16, 2024, 4:17:31 AMFeb 16
to RevitPythonShell
Thank you very much, I was keep getting error when trying to access the top two search results, but it is working ok today.
I will give it a try and sure will be back asking for help if needed.
Thanks again for your help

Hoss M

unread,
Feb 23, 2024, 12:56:00 PMFeb 23
to RevitPythonShell
Hello again,

is there a possibility to create a Tab during the process of RPS Addin, and add the panel / pushbuttons to the tab?

Thanks 

Callum

unread,
Feb 26, 2024, 3:30:52 PMFeb 26
to RevitPythonShell
Hi Hoss, it is possible to add Tabs and Panels when using a startupscript:
https://darenatwork.blogspot.com/2013/05/deploying-rps-scripts-with.html

But I dont think there is a way when you are adding a ribbon button from the RPS configuration interface:
Screenshot 2024-02-27 092609.png

Steven Williams

unread,
Feb 26, 2024, 9:29:53 PMFeb 26
to RevitPythonShell
I prefer to use pyRevit for this kind of work. It makes developing ribbons/tabs/buttons both easy and maintainable. At least this has been my experience in the past -- revitPythonShell for testing short scripts or API calls, the pyRevit to bundle things up in a ribbon.

Hoss M

unread,
Feb 27, 2024, 4:07:37 AMFeb 27
to RevitPythonShell
Pyrevit makes it very very easy indeed, but the ideal behind "Deploy RPS Addinn" is to be able to share your tools with others who don't have Pyrevit and Revit python shell installed on their PCs.

What i am hoping to achieve is similar to what has been show in this post

Hoss M

unread,
Feb 27, 2024, 4:08:13 AMFeb 27
to RevitPythonShell

Hoss M

unread,
Feb 28, 2024, 3:45:47 AMFeb 28
to RevitPythonShell
Hi, 
the following line in my start up script returning an error 
from RevitPythonShell.RpsRuntime import ExternalCommandAssemblyBuilder


ImportError: No module named RevitPythonShell.RpsRuntime

I am using Revit 2021
Thanks for your help

Callum

unread,
Feb 29, 2024, 3:56:52 AMFeb 29
to RevitPythonShell
Not sure why this would be. 

Does that import line work in a standard RPS Console window in a Revit session? It works when I run it there

Hoss M

unread,
Feb 29, 2024, 7:32:21 AMFeb 29
to RevitPythonShell
Same result
"" IronPython 3.4.1 (3.4.1.1000)
[.NETFramework,Version=v4.6.2 on .NET Framework 4.8.9195.0 (64-bit)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from RevitPythonShell.RpsRuntime import ExternalCommandAssemblyBuilder
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>

ImportError: No module named 'RevitPythonShell.RpsRuntime'
>>> ""

I have tried re-installing Revitpythonshell and still same result.
One thing that I have noticed is, I don't have anything in the Program files (x86) or  Program files.
Only place I could find  Revitpythonshell is within the addin folders, with the files inside:
test.jpg

Callum

unread,
Mar 1, 2024, 5:17:02 AMMar 1
to RevitPythonShell
Yeah thats strange that you dont have the installation files that I do. Mine are in the Program FIles (x86) folder - could be that Im using an older installation though (which uses different file locations). Anyone know how to look into the RevitPythonShell / RpsRuntime dlls and see if its missing the  ExternalCommandAssemblyBuilder assembly?

Otherwise (just stabbing in the dark), you could try 
"from RpsRuntime import  ExternalCommandAssemblyBuilder"

Hoss M

unread,
Mar 1, 2024, 6:05:18 AMMar 1
to RevitPythonShell
Hello Callum,

I tried 
Otherwise (just stabbing in the dark), you could try 
"from RpsRuntime import  ExternalCommandAssemblyBuilder"
 
and all working fine now, thanks for your help, greatly appreciated

Hoss M

unread,
Mar 1, 2024, 10:57:33 AMMar 1
to RevitPythonShell
In the simple_ribbon.py file , which will be used as start up script ( if I understood that correctly), does the DLL_PATH need to reflect the finished product path?
lets say I am planning to deploy the "HelloWorld" to revit 2022, will the path needs to be ....AppData\Roaming\Autodesk\Revit\Addins\2024\HelloWorldRibbon.dll

paths.jpg

could someone kindly share their working startup script so I can double check mine please?

My second question:
If some modules from "revitpythonwrapper" or "PyRevit" have been used in the script, how do you get them exported to the dll file?

Thanks again for your help and support
Reply all
Reply to author
Forward
0 new messages