I’m working on a top secret project. One of the tasks is modifying the profile view band labels to show information from a surveyed point’s description. I was having a bit of trouble finding were to grab the profile view band labels. The bands are a part of the Profile View object in .NET, but that only controls how the band shows the information.
In order to get the Profile Band Label Groups one has to use the GetAvailableLabelGroups static method (for 2012, in 2013 the updated method is called GetAvailableLabelGroupIds .
ProfileView profView = ssResult.ObjectId.GetObject(OpenMode.ForWrite) as ProfileView;
RXClass profDataBandLabelGroupRXClass = SystemObjects.ClassDictionary["AeccDbProfileDataBandLabeling"] as RXClass;
ObjectIdCollection profBandLabelsObjIdColl = ProfileBandLabelGroup.GetAvailableLabelGroups(profDataBandLabelGroupRXClass, profView.ObjectId, false);
Once I have the Label Group I can then use the information to modify the labels. The RXClass information I got from the Swamp.
No comments:
Post a Comment