Questions tagged [revitpythonshell]

RevitPythonShell is an Addin for Autodesk Revit that provides an IronPython console to run scripts within the Revit API. This addin allows to save and manage scripts from the Revit toolbar and offers convenient tools for scripts creation and deployment.

Installation

An installer is provided for all current Revit versions :

https://github.com/architecture-building-systems/revitpythonshell#installation


Contribution & Support

Github repository : https://github.com/architecture-building-systems/revitpythonshell

Google Discussion Goup : http://groups.google.com/group/RevitPythonShell

143 questions
6
votes
0 answers

.NET Assembly loses some methods when imported from one Python file into another (IronPython)

I have no idea, if this is a IronPython issue, a Revit API assembly issue, or something else. Any information/ideas on what could be causing this is appreciated. I understand this is solvable by re-importing the same namespace again, but I am dying…
gtalarico
  • 4,409
  • 1
  • 20
  • 42
6
votes
1 answer

create and assign subcategories in revit using python

I have a question for some of you who are familiar with the Revit API and python: I’ve been using the spring nodes package in dynamo to create a rather large series of freeform objects each in their own family. The way that the…
LuebkerJ
  • 61
  • 3
5
votes
2 answers

Accessing Revit API from outside Revit

I've used RevitPythonShell and Dynamo, but would like to use my existing Python IDE (Eclipse) where I have my configuration for logging, debugging, GitHub integration, etc. I'm comfortable with transactions and the overall API, and I've invested…
Marcus Jones
  • 960
  • 3
  • 11
  • 27
4
votes
3 answers

Ironpython write to Excel

I am trying to write data from Revit to Excel with RevitPythonShell. So far I have collected all data in a zipped list and made an enumerated for loop to write the data to the corresponding rows and columns as following: for index, data in…
Claus
  • 119
  • 1
  • 12
4
votes
0 answers

RevitPythonShell random module acting weird?

I am using the RevitPythonShell and after a frustratingly long search for a bug in my code, I found that the problem was due to the random module acting weird. Almost all the functions in the random module seem to leave half of the possibilities…
4
votes
3 answers

How can I activate (display) a view using Revit API?

I am trying to activate a view using Revit API. What I want to do exactly is to prompt the user to select some walls, but when the user is asked that, he can't switch views to select more walls (everything is greyed out at that point). So the view…
Arnaud
  • 445
  • 4
  • 18
3
votes
1 answer

Can't prompt the user to pick a room with Revit Python Shell

Using the Revit Python Shell, I'm trying to prompt the user to pick a room. I've been reading and implementing the method described here Revit Python Pick Object / Select Object . It works fine, but using that I can only select walls, floors, doors,…
Arnaud
  • 445
  • 4
  • 18
3
votes
1 answer

IronPython WPF withe RevitPythonShell

I've written this script based on the snippets I found here on stackoverflow but get this error at runtime: System.InvalidOperationException: Cannot create more than one System.Windows.Application instance in the same AppDomain. I know it's got…
Ehsan Iran-Nejad
  • 1,697
  • 1
  • 15
  • 20
2
votes
1 answer

How to create square of walls via WPF in Revit python

I start learning pyRevit and here's the trouble. I want to create a WPF where I may enter values then Revit could would automatically construct a simple rectangular building. I have already create a WPF but I'm stuck in part where I need to connect…
John
  • 29
  • 2
2
votes
3 answers

ExtensibleStorage using RevitPythonShell

I am trying to take advantage of ExtensibleStorage in the Revit API. I'm trying to store an Array in a ArrayField. I think maybe my errors are due to the IronPython interface, but maybe someone has done this successfully? I know that the object to…
Kyrre
  • 85
  • 1
  • 5
2
votes
1 answer

Google.Apis.Auth 1.46.0.0 is installed but then being asked for multiple versions

I am able to get Firestore access through winforms by itself and it works. however, if I try to access Firestore through an external command, I get an error: System.IO.FileNotFoundException: 'Could not load file or assembly 'Google.Apis.Auth,…
Cflux
  • 1,423
  • 3
  • 19
  • 39
2
votes
1 answer

RPS: Cannot import name ExporterIFCUtils

With the revitpythonshell 2020 I try to import the class ExporterIFCUtils from Autodesk.Revit.DB.IFC import ExporterIFCUtils and get the error: "Exception : IronPython.Runtime.Exceptions.ImportException: Cannot import name ExporterIFCUtils"
StefanAnd
  • 21
  • 2
2
votes
1 answer

Revit 2020 API - Family Document active view returning null after Family document is open and activated

I'm trying to get the active view of my family's document but it returns null. In Revit 2019, it would always return a value however I've recently switched to Revit 2020 and it seems to be giving me an issue. Has anyone else run into this yet and…
Cflux
  • 1,423
  • 3
  • 19
  • 39
2
votes
3 answers

How to import Revit and pyRevit librairies with PyCharm?

This is my very first question here, hope won't be my last. As I already use some answers from a lot of people, I would like to start by thanking all of you. Context : I'm developing a module for Revit, and for this, I'm using pyRevit to exchange…
Speculoos
  • 23
  • 5
2
votes
1 answer

Revit ribbonpanel pushbutton with Bitmap Image without RevitPythonShell or C# (ironpython only)?

I am an architect (real one, not software architect :) ) experimenting a bit with Revit API and introducing myself into coding world. I have done a part with C# but switched to Python with hope that initial steps will go faster this way. To get…
darkhitect
  • 55
  • 1
  • 6
1
2 3
9 10