Here are two important utilities, one eagerly awaited, the other a nice surprise: the updated REX and Structural analysis SDKs and a powerful
await wrapper for the Revit API external event
– REX SDK and Structural Analysis SDK 2020
– Standard approach
– Revit.Async approach...
The hugely popular Design Automation APIs for Revit, Inventor, and 3ds Max will be officially released to the public on October 28. In a completely different vein, I found a very simple solution to download photos from an Android phone to the Mac – Public Forge Design Automation APIs – What can you do with Design Automation API for Revit? – Easy solution to transfer photos from Android to Mac – Gadgets in 1990 vs. 2018...
Continuing the update of my development environment for Revit 2020, I now turn to the Visual Studio Revit add-in wizards. I'll also highlight a couple of recent interesting AEC related job offers, an AI 101 intro, and some really important suggestions on how to ask a question well – C# and VB Visual Studio add-in wizards for Revit 2020 – How to ask a question well – Open Autodesk AEC related positions – AI for all...
Revit 2020 has been released, and we go through the same procedure as every year, looking at the DevDays online presentations highlighting the API news, getting the system requirements set up, installing, compiling the Revit SDK samples and setting up RvtSamples to load them – Revit 2020 first customer shipment – Revit 2020 DevDays Online – Setting up Windows 10 – Installing Revit 2020 and the new SDK – Visual Studio and .NET 4.7 – Compiling the Revit 2020 SDK samples – Setting up RvtSamples...
Håvard Leding of Symetri raises another exciting topic on using the the
GetDependentElements method to retrieve and snoop dependent elements, e.g., the sketch of a floor and the model lines defining the floor boundary in that sketch
– Snoop dependent elements
– RevitLookup update...
Happy New Year! I spent some time during the winter break working on CSV export of room boundaries for a Forge BIM surface classification tool. Ali Asad presented a new Visual Studio WPF MVVM Revit add-in template – Export room boundaries to CSV for Forge surface classification – Visual Studio WPF MVVM Revit add-in template...
Let's highlight a nice interactive didactical Python-based Revit API learning challenge on how to get the bounding box from a Revit element and determine its centre – Cyril's Python HVAC blog – Rotating elements around their centre in Python – Retrieve element and bounding box from picked reference – Use location point instead of bounding box centre – Final working solution...
I updated the Visual Studio Revit C# and VB add-in templates for Revit 2019. They enable you to create a new C# or VB Revit add-in in Visual Studio with one single click on File > New > Project... > Visual Basic/Visual C# > Revit 2019 Addin and define a complete skeleton Revit add-in, ready to immediately compile and run, including an add-in manifest file, external application and external command. Just hit F5 to start debugging; the add-in manifest is installed, Revit launched and the command is immediately available...
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...
I already described how I installed Revit 2019, compiled the Revit 2019 SDK samples and migrated RevitLookup to the new version.
I now migrated some of the other basic samples and utilities and have some Forge news to share
– The Building Coder samples for Revit 2019
AdnRme MEP HVAC and electrical samples for Revit 2019
– AdnRevitApiLabsXtra for Revit 2019
– Convert RVT to IFC via Forge
– Forge accelerators
– Forge webinars
– Open position for an infrastructure BIM implementation consultant...
A discussion with Håvard Dagsvik on the use of
TransmissionData, standalone access to the
BasicFileInfo without the need for a valid Revit API context, and a Revit-independent method replacing
– No document required for
TransmissionData requires a valid Revit API context
GetFamilyXmlData method replacing
– Windows explorer
BasicFileInfo right click utility...
Александр Пекшев aka Modis @Pekshev submitted a very succinct and useful pull request for RevitLookup that I integrated right away, and provides many other valuable inputs as well – Snoop stable representation of References – Project point on plane correction – Revit export geometry to AutoCAD via XML – RevitExportGeometryToAutocad – Description – Versions – Using – Example...
An add-in will often need to retrieve the elements that it just created for further processing. Frequently, the Revit API method used to create them will return their element ids. Sometimes, that is not the case. Now this topic arose again in a couple of cases and brought some other aspects to mind – Using the element lister – Consecutive element ids – Retrieving recently added elements – AEC job openings in Munich and elsewhere...
Revitalizer shared two important hints: a performance issue using
ElementTransformUtils and a problem reporting mechanism built into the
First, though, let's highlight an even more important upcoming event, the series of DevDays online webinars
– Register now for Autodesk DevDays online webinars
– Avoid using
ElementTransformUtils for batches
– Finding cause of
DirectShape generation problem...
I went on my first ski tour this season...
lots of interesting issues in
the Revit API discussion forum...
a Japanese case on programmatically generating a mass floor, enabling us to mention yet another hitherto unmentioned Revit API usility class,
Please tell me if a method exists to generate a mass floor using the API...
I completed the presentation and recording of my presentation yesterday on Rational BIM programming using Revit and Forge at Autodesk University in Darmstadt, Germany
– Rational BIM Programming recording
– Pleasant walks in the Odenwald
– Some of my favourite recent books
– Where to continue after finishing school
– New AlphaGo Zero is completely self-taught
I am attending the Forge DevCon conference in Darmstadt, Germany, right now, and putting the final touches to my presentation on Rational BIM programming using Revit and Forge at the European Autodesk University on Wednesday. We discussed several different approaches to retrieve the outer loop of a planar face. Richard Thomas recently shared a possible solution to determine the outer-most EdgeLoop. He now posted a new approach: I found a more straightforward and likely reliable way of getting outer loops of planar faces. This method also allows for faces made up of disjointed parts...
I spent last week working on a new little BIM sample showing a round trip connection between Revit and Forge, and an automated way of generating and populating shared parameters from spreadsheet data – RvtMetaProp – Revit meta property add-in – CSV and JSON input file format – Forge configurator sample – Round-Trip Forge meta property editor – BipGroupList lists built-in parameter group enums and labels – Two options to add custom properties to the Revit BIM – Translation of shared parameters to Forge – Handling BIM floors in Forge...
Håvard Dagsvik of Symetri implemented code to automatically generate a dictionary mapping the Revit
DisplayUnitType to corresponding
UnitSymbolType display strings. The developer guide describes these classes like this
– UnitType – type of physical quantity to be measured, for example length or force (UT_Length or UT_Force)
– DisplayUnitType – units and display format used to format numbers as strings or convert units (i.e. DUT_METERS)
– UnitSymbolType – unit symbol displayed in the formatted string representation of a number to indicate the units of the value (i.e. UST_M)...
A biggish post rather late in the week... still answering too many cases – Forge for AEC demos and sample code – Determining the starting view – Detecting installed Revit version – Detecting installed C3D version – Moving items inside a detail group – Filtering for family instances and types by family name...
I am away on vacation. In the meantime, Roman Lavrov shared his Revit Family Browser, saying: I am working on family browser for Revit using Revit API and WPF. Your blog helps me a lot, so I decide to share my work with you. I think, some ideas will be useful for other coders. If you have time, please take a look my program on GitHub at github.com/RomanLavrov/RevitFamilyBrowser...
I already discussed the first clean-up of the new
Reflection based version of RevitLookup; here comes the second one, restoring access to view extensible storage data
– Recent changes to RevitLookup
– Restore access to extensible storage data
– Download and access to old functionality...
Last week, I presented Andrey Bushman's new Visual Studio templates for Revit add-ins. Furthermore, we discussed many aspects of edit and continue in the past, including the solution to use the Add-in Manager. These two topics have now met and united, because Andrey added support for that and a bunch of other new functionality in his commit...
Last week, I presented a drastic change to RevitLookup using
Reflection to provide more complete coverage of all the Revit database element methods and properties. Victor Chekalin took a critical look at this new version and cleaned it up significantly. Now all is well and order has been restored again
– Shock and gripe
– Commit summary
– 1. Methods and properties extraction
– 2. Show enum values
– 3. Drill down into
– 4. Remove duplicate
get_ property getter method
– 5. Fixed
– 6. Visual style of separator
– Download and access to old functionality
– Reaction and read-only assurance...
I have been maintaining a simple Visual Studio Revit add-in wizard for a number of years. Now Andrey Bushman implemented a set of more advanced and convenient Visual Studio templates for creation of Revit add-ins for his own use. The discussion of those led us to once more revisit the topic of the Visual Studio settings for debugging Revit add-ins – New Visual Studio 2015 templates for Revit add-ins – Use Managed Compatibility Mode or Enable Native Code Debugging? – Machine learning software engineer job in Switzerland – FreeCodeCamp...
Today, I present a large and drastic contribution to RevitLookup from Andy @awmcc90 McCloskey of RevDev Studios that will help significantly in supporting both past and future releases of Revit
– Drastic changes making use of object inspection via
– Cross version compatibility
– Removal of events and unused functionality
– Commit summary
– File Changes
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...
Happy New Year to one and all! I had a great break over Christmas and New Year and hope you did as well. I continued checking into the Revit API discussion forum throughout and had several interesting discussions with the busy souls hanging out there – C++, audio, crypto and security – Prayer of the Mothers – Avoid remaking CAD content...
Some people have recently reported that they encountered models lacking the
ProjectInfo project information singleton element.
Apparently, it was possible in previous versions of Revit for a faulty or malicious add-in to simply delete this element.
That obviously causes problems for other add-ins and Revit itself, who rely on its presence.
Luckily, it is not hard to fix.
Here is the latest discussion addressing this issue...