Creating wall by profile by Python


#1

Here is a code which creates a wall by profiles in Revit API

http://revitapisearch.com/html/6c247699-c8e5-91df-67f7-470d10fa7ba3.htm

How can I use this method in Python Script for Dynamo?

I’d like to create walls by using perimeter profiles which created in Dynamo. because the original wall node can create only rectangular ones.

Thanks.


#2

Hi Kim,

Have a look here:

http://dynamobim.com/forums/topic/trim-revit-walls-to-imported-surface/


#3

Thanks Dimitar, I’ll look into it.


#4

Thanks for the link. Have you been successful Hyunu? I’m quickly finding that I need to get into the Revit API to do what I’m after, plus Python.

My goal at the moment, given there is no Dynamo node to do this, is to query a Revit object that is created through the Draw gallery with a curve and retrieve that curve. For example walls, conduit, pipes, duct and cable tray. I’m just interested in straight lines at this point and am wondering if through Python, I can access this information via the Revit API. That’s my next endeavor and would love to hear from anyone if this is possible and perhaps see a code snippet of how it’s done.


#5

Hi David!

What exactly do you need to extract? You can get the length pretty easy. And if you use Clockwork’s Element.Location node you can get the start/end points of the sketch based element.

 

Cable Tray


#6

Hi Dave,

Like Paul said, the code at the link is not about querying but about creating. And yes, Dimitar’s code was exactly what I was looking for.

Here is a demo of my creation. I modified the code just a little.

https://youtu.be/MP0_XkO9AnY

Thanks, Dimitar.


#7

Kim, I may have a simpler workflow for this topo thing:

  • create a floor bigger than the topo footprint

  • get the points from topo

  • edit the floor with Fllor node from Clockwork

  • attach base of the walls to the floor

  • hide the floor

enjoy!!

topo walls


#8

Hey Paul! How are you mate?

You know, you just saved me a bunch of time. That custom node does exactly what I need (and great thanks to Andreas Dieckmann for the package!). I just need the start & end points of a few two-point placement categories. I just need to evaluate whether they are linear and treat curved ones differently. I think I can take the Python code and adapt it. I can reverse engineer something pretty good usually, but just didn’t know where to start! Thanks a ton, I owe you one :slight_smile: