Skip to content

Instantly share code, notes, and snippets.

@cdiggins
Created July 15, 2025 15:37
Show Gist options
  • Save cdiggins/5112c98b86ce5daca9f28a5f504f637b to your computer and use it in GitHub Desktop.
Save cdiggins/5112c98b86ce5daca9f28a5f504f637b to your computer and use it in GitHub Desktop.
Built in Revit API data as parameters
public void CreateCommonDescriptors()
{
AddDesc(ref _apiTypeDescriptor, "rvt:Object:TypeName");
AddDesc(ref _elementLevel, "rvt:Element:Level");
AddDesc(ref _elementLocation, "rvt:Element:Location.Point");
AddDesc(ref _elementLocationEndPointA, "rvt:Element:Location.EndPointA");
AddDesc(ref _elementLocationEndPointB, "rvt:Element:Location.EndPointB");
AddDesc(ref _elementBoundsMin, "rvt:Element:Bounds.Min");
AddDesc(ref _elementBoundsMax, "rvt:Element:Bounds.Max");
AddDesc(ref _elementAssemblyInstance, "rvt:Element:AssemblyInstance");
AddDesc(ref _elementDesignOption, "rvt:Element:DesignOption");
AddDesc(ref _elementGroup, "rvt:Element:Group");
AddDesc(ref _elementWorkset, "rvt:Element:Workset");
AddDesc(ref _elementCreatedPhase, "rvt:Element:CreatedPhase");
AddDesc(ref _elementDemolishedPhase, "rvt:Element:DemolishedPhase");
AddDesc(ref _elementCategory, "rvt:Element:Category");
AddDesc(ref _familyInstanceToRoomDesc, "rvt:FamilyInstance:ToRoom");
AddDesc(ref _familyInstanceFromRoomDesc, "rvt:FamilyInstance:FromRoom");
AddDesc(ref _familyInstanceHost, "rvt:FamilyInstance:Host");
AddDesc(ref _familyInstanceSpace, "rvt:FamilyInstance:Space");
AddDesc(ref _familyInstanceRoom, "rvt:FamilyInstance:Room");
AddDesc(ref _familyInstanceSymbol, "rvt:FamilyInstance:Symbol");
AddDesc(ref _familyInstanceStructuralUsage, "rvt:FamilyInstance:StructuralUsage");
AddDesc(ref _familyInstanceStructuralMaterialType, "rvt:FamilyInstance:StructuralMaterialType");
AddDesc(ref _familyInstanceStructuralMaterialId, "rvt:FamilyInstance:StructuralMaterialId");
AddDesc(ref _familyInstanceStructuralType, "rvt:FamilyInstance:StructuralType");
AddDesc(ref _familyStructuralCodeName, "rvt:Family:StructuralCodeName");
AddDesc(ref _familyStructuralMaterialType, "rvt:Family:StructuralMaterialType");
AddDesc(ref _roomNumber, "rvt:Room:Number");
AddDesc(ref _roomBaseOffset, "rvt:Room:BaseOffset");
AddDesc(ref _roomLimitOffset, "rvt:Room:LimitOffset");
AddDesc(ref _roomUnboundedHeight, "rvt:Room:UnboundedHeight");
AddDesc(ref _roomVolume, "rvt:Room:Volume");
AddDesc(ref _roomUpperLimit, "rvt:Room:UpperLimit");
AddDesc(ref _levelProjectElevation, "rvt:Level:ProjectElevation");
AddDesc(ref _levelElevation, "rvt:Level:Elevation");
AddDesc(ref _materialColorRed, "rvt:Material:Color.Red");
AddDesc(ref _materialColorGreen, "rvt:Material:Color.Green");
AddDesc(ref _materialColorBlue, "rvt:Material:Color.Blue");
AddDesc(ref _materialShininess, "rvt:Material:Shininess");
AddDesc(ref _materialSmoothness, "rvt:Material:Smoothness");
AddDesc(ref _materialCategory, "rvt:Material:Category");
AddDesc(ref _materialClass, "rvt:Material:Class");
AddDesc(ref _materialTransparency, "rvt:Material:Transparency");
AddDesc(ref _worksetKind, "rvt:Workset:Kind");
AddDesc(ref _layerIndex, "rvt:Layer:Index");
AddDesc(ref _layerFunction, "rvt:Layer:Function");
AddDesc(ref _layerWidth, "rvt:Layer:Width");
AddDesc(ref _layerMaterialId, "rvt:Layer:MaterialId");
AddDesc(ref _layerIsCore, "rvt:Layer:IsCore");
AddDesc(ref _documentCreationGuid, "rvt:Document:CreationGuid");
AddDesc(ref _documentWorksharingGuid, "rvt:Document:WorksharingGuid");
AddDesc(ref _documentTitle, "rvt;Document:Title");
AddDesc(ref _documentPath, "rvt:Document:Path");
AddDesc(ref _documentElevation, "rvt:Document:Elevation");
AddDesc(ref _documentLatitude, "rvt:Document:Latitude");
AddDesc(ref _documentLongitude, "rvt:Document:Longitude");
AddDesc(ref _documentPlaceName, "rvt:Document:PlaceName");
AddDesc(ref _documentWeatherStationName, "rvt:Document:WeatherStationName");
AddDesc(ref _documentTimeZone, "rvt:Document:TimeZone");
AddDesc(ref _projectName, "rvt:Document:Project:Name");
AddDesc(ref _projectNumber, "rvt:Document:Project:Number");
AddDesc(ref _projectStatus, "rvt:Document:Project:Status");
AddDesc(ref _projectAddress, "rvt:Document:Project:Address");
AddDesc(ref _projectClientName, "rvt:Document:Project:Client");
AddDesc(ref _projectIssueDate, "rvt:Document:Project:IssueDate");
AddDesc(ref _projectAuthor, "rvt:Document:Project:Author");
AddDesc(ref _projectBuildingName, "rvt:Document:Project:BuildingName");
AddDesc(ref _projectOrgDescription, "rvt:Document:Project:OrganizationDescription");
AddDesc(ref _projectOrgName, "rvt:Document:Project:OrganizationName");
AddDesc(ref _categoryCategoryType, "rvt:Category:CategoryType");
AddDesc(ref _categoryBuiltInType, "rvt:Category:BuiltInType");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment