
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi, I am dealing with this problem:
How can I get exact element which belongs to caregory BuiltInCategory.OST_AnalyticSpaces from EnergyAnalysisDetailModel?
I will try to explain:
1. I created some parameters (shared parameters) and binded them to all AnalyticSpaces like this:
InstanceBinding newInstanceBinding = uiApp.Application.Create.NewInstanceBinding(categorySet);
doc.ParameterBindings.Insert(definition, newInstanceBinding, BuiltInParameterGroup.PG_IDENTITY_DATA);
So i believe that user can edit values of those parameters...
After that i created Energy analysis Detail Model like this:
EnergyAnalysisDetailModelOptions options = new EnergyAnalysisDetailModelOptions();
options.Tier = EnergyAnalysisDetailModelTier.Final;
options.EnergyModelType = EnergyModelType.SpatialElement;
EnergyAnalysisDetailModel eadm;
using (Transaction tr = new Transaction(doc, "Create EnergyAnalysisDerailModel"))
{
tr.Start();
eadm = EnergyAnalysisDetailModel.Create(doc, options);
tr.Commit();
}
Everything is correct and is working so far but now comes the problem:
So now i can get analytical spaces from energy analysis model:
IList<EnergyAnalysisSpace> spaces = eadm.GetAnalyticalSpaces();
But, there i am stucked for 2 days, because i dont know how to get that parameters and associate them with those EnergyAnalysisSpaces....
Anybody knows how to do it?
(I am sorry for my english, and i am newbie in revit api)
Solved! Go to Solution.