logo

teocomi


Sometimes I write about code & tech in the AEC industry.
Co-founder of Speckle.
Formerly Arup, Foster+Partners, WeWork, CASE Inc.


Revit API 2013 IfcProject Guid in C#

Using Revit API version 2013 in order to get the IfcGuid of the current project it is possible to use the following code:

UIDocument uidoc = commandData.Application.ActiveUIDocument;
Document doc = uidoc.Document;
string ifcproject = ExporterIFCUtils.CreateProjectLevelGUID(doc, Autodesk.Revit.DB.IFC.IFCProjectLevelGUIDType.Project);

The returned Guid will be the same, for instance, of an IFC file used in Solibri. Remember to add this to your Namespaces:

using Autodesk.Revit.DB.IFC;

comments powered by Disqus