Associate shared parameter from OST_AnalyticalSpace to EnergyAnalysisDetailModel

Anonymous

Associate shared parameter from OST_AnalyticalSpace to EnergyAnalysisDetailModel

Anonymous
Not applicable

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)

 

 

0 Likes
Reply
Accepted solutions (1)
540 Views
2 Replies
Replies (2)

Anonymous
Not applicable
Accepted solution

Okay so i found the answer 🙂

 

I can do that with CADObjectUniqueId

Because both surfaces have same CADObjectUniqueId

 

I hope it will also help somebody else 🙂  

0 Likes

Anonymous
Not applicable

Okay so i found the answer 🙂

 

I can do that with CADObjectUniqueId

Because both surfaces have same CADObjectUniqueId

 

I hope it will also help somebody else 🙂  

0 Likes