Questions tagged [revit-api]

Revit's API allows users to create customizations of the Autodesk Revit environment with tools that can greatly enhance end users' capabilities. The program is built around Microsoft's .NET Framework.

Revit's API allows users to create customize the environment with tools that can greatly enhance end users capabilities. The program is built around Microsoft's .NET Framework.

Resources:

Forums:

977 questions
3
votes
1 answer

How to increase the speed of finding elements?

This code performs extremely long time and in the end, doesn't accomplish its goal - combine element's parameters inside of a schedule. It clearly happens due to a large number of elements of the category "Pipe Fitting" in the project. How to…
fysharp
  • 101
  • 7
3
votes
0 answers

export revit data to sql

I have some projects in Revit. when I export data to sql database of those projects, instead of adding records it overwrites previous records. how do I fix it. There is a single database where records of all projects are to be saved
toadgs
  • 43
  • 4
3
votes
2 answers

How do I raise an external event in the Revit API from a WPF app?

I have been trying to create a Revit plugin that allows the user to view issues that are stored on a remote server on the local version of the file. It should create a new 3D perspective view from the stored data on the server and open it in Revit.…
Tom Paganuzzi
  • 45
  • 1
  • 4
3
votes
2 answers

c# - Revit api - multi version plugin .csproj file

I'm trying to create a simple multi-version hello World plug-in for Revit and I've found this article which I'm trying to follow along. however, I'm not getting very far. I'm not so familiar with how the .csproj file works. I've created plugins…
Cflux
  • 1,423
  • 3
  • 19
  • 39
3
votes
2 answers

Revit API. How can I get bounding box for several elements?

I need to find an outline for many elements (>100'000 items). Target elements come from a FilteredElementCollector. As usual I'm looking for the fastest possible way. For now I tried to iterate over all elements to get its BoudingBox.Min and…
arn9000
  • 133
  • 1
  • 10
3
votes
1 answer

pyRevit WPF non-modal trouble

So I'm just starting to dip my toes into WPF in pyRevit. I tried to implement the pyrevit.forms.WPFWindow Class like this: # -*- coding: UTF-8 -*- """ Third-Party software credits: pyRevit: repository at…
Kyrre
  • 85
  • 1
  • 5
3
votes
1 answer

TreeView adding and sorting

I have treeView sorted in my Autodesk Revit and I would like to show it same way in my windows form. At this time I was able to extract it just the way it looks in Revit (print log), but i cant figure out how to add it. Here's what I've done so…
Mbanch
  • 98
  • 6
3
votes
0 answers

Getting the Dimensions of 3D Views in Revit Document

I want get list of 3DViews in comboBox from revit. I create plugin. And I have to get height and width selected 3DViews. When I start my plugin I get list of 3DViews, but I don't know how get height and width selected 3DViews. What methods or else…
Spike
  • 43
  • 7
3
votes
3 answers

Get all parameters of Schedule and Material Takeoff

I am creating plugin for Revit 2019 and want to get all the parameters of Wall Category. I have filtered the walls and then I am accessing parameters of wall. But I am not getting the parameters like "Material: Name, Material: Area, Material:…
Mah Noor
  • 83
  • 1
  • 11
3
votes
0 answers

Should I create a ViewModel for each item in an ObservableCollection

Being fairly new to MVVM in WPF I am running into a dilemma of what items need their own ViewModel. I am writting a plugin for Autodesk's Revit program. Using the provided API I am drilling into the parameters of elements and performing engineering…
jnyp
  • 57
  • 4
3
votes
1 answer

Control Events- Revit API

I would like to control events of Load Families and Create Type with revit api. Someone can give me a direction ? I don't understand very well the documentation that I read.
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
3
votes
3 answers

Prevent Revit window from opening

I'm trying to intercept Revit and keep a window from opening. Specifically, I'm trying to apply a keynote to an object and then let the user create a keynote tag, however any way I do it it lets them place the keynote but then immediately gives…
sfaust
  • 2,089
  • 28
  • 54
3
votes
2 answers

How to generate a compiler error based on an attribute being missing in C#?

I create a number of add-ins for the Revit Structure API. Each tool has to habe a class which implements the interface IExternalCommand. In the latest version of Revit, for your tool to work you need to have two attributes on the class that…
RodH257
  • 3,552
  • 5
  • 36
  • 46
1
2
3
64 65