An example of real-time live graphical user input feedback, cloud model functionality, the ever important need to regenerate and other important topics for this holiday day – Line angle and direction jig – Determine cloud model local file path – How to refresh GroupType.Groups – Online access to RevitAPI.chm help files – C++/C# frontend engineer...
A lengthy and fruitful conversation on implementing valid rebar stirrup constraints and more advice on determining boundary elements for the entire building and individual rooms – Rebar stirrup constraints – Exterior bounding walls – All walls including non-bounding interior walls – Floors and ceilings – Revit API and UX style guide – Today's collective action problem...
A quick look at various methods to integrate transient graphics into Revit and pointers to articles of interest on other current non-API-related topics such as chess AI, basic income and the effectiveness of lockdowns – Transient graphics – AI learns to emulate human-style chess – Basic income as fault-tolerant engineering – Lockdown effectivity...
Many interesting topics on pure Revit API, Forge, BIM360 and AI – Custom export precision – Dismissing a Windows dialogue with JtClicker – AU classes for construction customers – Retrieve sheet metadata in Forge viewer – Determining the BIM 360 project id – AI solves partial differential equations – AI-enhanced video editing...
Today we pick up two recent MEP related discussions, on creating a new pipe connector for a hydraulic fitting family and on automatic pipe system routing, and a couple of other odd items
– The names they are a-changin
– Getting a
– Auto-routing a pipe system between plumbing fixtures
– Handling dialogue and failure messages
– Retrieving a geometry reference...
We recently shared a brief note on using the
BreakCurve API for splitting a pipe.
Matt Taylor now pointed out a much more comprehensive discussion asking, is there any API available to split a duct programmatically?
That is not just an example, but an entire tutorial, so I think it is very useful to share here as well for all to enjoy..
So many interesting things going on in the Revit API discussion forum.
Also, the newest DA4R recording is now available online
– Forge Design Automation API for Revit recording
– Design Automation for Revit supports IFC
– What does the
includeShadows flag do?
– Easiest solution to deploy add-in
– Always show the same button in
The ultimatively painless introduction to the Forge Design Automation API, a solution for creating two stacked ribbon items, reinitialising filtered element collectors and picking a face in a linked file
– Forge Design Automation API webinars
– Stacking two 24x24 ribbon items
– Reinitialising the filtered element collector
CreateReferenceInLink to select a face in a linked file...
As high-resolution monitors grow ever more common, an important question arises on handling add-in scaling for 4K high resolution screens – Problem adapting a Revit add-in for 4K displays – Application properties for stand-alone apps – Application manifest – Separate UI component with IPC – Two solutions for adjusting Revit for 4K displays – Method 1 – Run hires monitor in low resolution – Method 2 – Adjust how Revit handles 4k displays – Discussion of the results...
I'll start this week with several solutions from the Revit API discussion forum and elsewhere, especially two different approaches to create rotated rebar stirrups – Embedded tooltip icon resource – Revit 2019 tooltip videos are MP4 – How to read and write bolt, plate and weld – Creating rotated rebar stirrups...
Today is The Building Coder's tenth birthday! The first post was a warm welcome on August 22, 2008. Very many thanks to the entire community for all your support, interest, comments and above all numerous contributions over the years! Today, let's pick up the recurring topic of accessing the Revit API from a modeless context...
The Failure API enables both failure definition and handling capabilities – The ability to define and post failures from within API code when a user-visible problem has occurred – The ability to respond to failures posted by Revit and by API code through code in your application This also enables the creation of a modeless warning message to the user...
Every time I created a ribbon button, I was faced with the task of creating appropriately scaled icons for it to populate the
PushButton large and small image icon properties
They seem to expect a 32 x 32 and 16 x 16 icon, respectively.
I finally solved that once and for all by implementing a couple of methods to perform automatic bitmap scaling
– BitmapImageToBitmap – convert a
– BitmapToBitmapSource – convert a
Bitmap to a
– ResizeImage – resize an image to the specified width and height
– ScaledIcon – scale down large icon to desired size for Revit ribbon button
– Usage sample – putting them together...
Dragos Turmac of the Revit development team solved the Revit API discussion forum questions on contextual help not working from within a command and on F1 help for add-in only by explaining the current best practice to implement online help – Question: I'm trying to add contextual help for all commands (press F1 to go to a location). It's working fine when the tooltip is shown for my commands, but, when the add-in form is open, pressing F1 opens the Autodesk knowledge site for Revit instead...
Two recent Revit MEP related cases brought up some new information on the pipe
K factor table and custom calculations for pipe fittings, the Forge DevCon class recordings are now available, and I discovered Konrad Sobon's wonderful archi+lab Revit API blog, which helps resolve an installation and setup issue
K factor table
K factor calculation for pipe fittings
– Dynamo code to change loss coefficient
– Forge DevCon 2017 class recordings
– Revit add-in installer and buttons...
I am back from a nice break in Italy. Next, I am attending the European Autodesk University in Darmstadt, Germany. Meanwhile, solutions for two issues on keeping Revit focused and on top when working with a modeless form, and an important heads-up warning from the Revit development team on a future change coming. We here at Ideate Software are seeing what appears to be Revit add-in ownership issues with Revit's main window. The behavior has changed between Revit 2017 and Revit 2018 for modeless add-ins. For Revit 2018, when a modeless add-in is closed, Revit does not retain is focus; it is pushed behind another application...
In Revit 2018, cancelling family instance placement during a call to
PromptForFamilyInstancePlacement throws an
– Easily fixed, once discovered
– Change in Behaviour
– Exceptions Should be Exceptional
– The Building Coder samples
Today is the last day of the Forge accelerator, and I am still working on the ForgeFader project. The topics today are mainly related to Revit, though – Google prettifier on GitHub – WTA mechanical family placement add-in – Provision for void – What is a provision for void? – Creating a provision for void...
Here is a summary of the discussion and solution for setting
ActiveView during the
Idling event from the Revit API discussion forum raised and solved by Rudi 'Revitalizer' and Kinjal Desai; As per API documentation, this operation should not be invalid: no open transactions;
IsModifiable is ok;
IsReadOnly is ok; No pre-action events around. However, trying to do so throws an
InvalidOperationException with the message "Setting active view is temporarily disabled"...
Lots of information on, from and about schedule parameters, and a new elegant solution to a long-standing challenge – Direct access to shared parameter GUID – Getting parameter information from a schedule...
I continued my activity in the Revit API discussion forum and had lots of interesting discussions there. One recent thread caused me to bring up a favourite topic of mine, on keeping things simple. I'll also mention two other less recent recurring questions – Distance between two points in a specific direction – Revit command-line switches – Keeping things simple with the Revit API – Dino pondering lengthening days...
Topic: a C# .NET Revit add-in demonstrating use of a split ribbon button to access a secondary command, e.g., option settings. In the Revit API discussion forum thread on using a
StackButton as a
PushButton with options, Allan 'aksaks' Seidel recently proposed a neat UI trick, saying: Perhaps this idea might be usable for others. The
StackButton ribbon control is a stack of different
PushButton instances where the last used
PushButton remains visible to be used again. That visible button is reflected in the stack button's
CurrentButton property. Imagine if the
StackButton control always shows the first button in the stack, and the other button(s) are secondary to the first button's purpose...
Last night, I migrated The Building Coder samples to Revit 2017 – Flat Migration – Updated RvtSamples Include File – Automatic Transaction Mode is Obsolete – Obsolete Plane Constructors and NewPlane Methods – Obsolete NewPlane Method Taking a CurveArray Argument – Replace View.SetVisibility by SetCategoryHidden – Use DirectShape ApplicationId and ApplicationDataId – All Obsolete Revit API Usage Eliminated...
Today, I address the first item in yesterday's to do list
– Document and improve FireRatingClient, the stand-alone Windows client – we will need this to demonstrate the real-time BIM update from arbitrary sources
– Adding the
– Updating the
modified Field on Edit
– FireRatingClient Live BIM Update Demo Recording
– To Do...
Yesterday, I migrated RoomEditorApp to Revit 2017 and mentioned the BIM and cloud related projects I am working on. Next, let's focus on the FireRatingCloud sample. The main goal there is to implement fully automatic real-time BIM update from the cloud. Now, 24 hours after writing the previous sentence, I can tell you that I succeeded. Well, add another six hours to edit this post... Here is the updated FireRatingCloud custom ribbon tab with its new set of commands...