The EnergyDataSettings object contains settings for gbXML Export and Heating and Cooling Load Calculations and project level settings for Conceptual Energy Analysis.
The EnergyDataSettings object is derived from the Element base object. It is unique in each project, similar to ProjectInformation. Though EnergyDataSettings is a subclass of the Element class, most of the members inherited from the Element return null or an empty set except for Name, Id, UniqueId, and Parameters.
The following code sample uses the EnergyDataSettings class. The result appears in a TaskDialog after invoking the command.
Code Region 28-7: Using the EnergyDataSettings class |
public void GetInfo_EnergyData(Document document) { EnergyDataSettings energyData = EnergyDataSettings.GetFromDocument(document); if (null != energyData) { string message = "energyData : "; message += "\nBuildingType : " + energyData.BuildingType; TaskDialog.Show("Revit", message); } } |