Hi.
I am having trouble reading text in labels of templates, I can read the lable name but I dont know how to get the text from it.
Here is the code Im using:
Dim collector AsNewFilteredElementCollector(ExtCmd.CachedUiApp.ActiveUIDocument.Document)
Dim collection AsICollection(OfElement) = collector.OfClass(GetType(ViewSheet)).ToElements()
ForEach element AsElementIn collection
If SKRTegund = element.Name.ToString Then
Dim planView AsViewSheet = Nothing
Dim views AsList(OfElement) = collector.OfClass(GetType(View)).ToElements
ForEach v AsViewIn views
If v.Name = SKRTegund Then
planView = v
Dim IDS AsIList(OfElementId) = planView.GetTemplateParameterIds
ForEach stre In IDS
If stre.IntegerValue > 0 Then
Dim Elllem AsElement = ExtCmd.CachedDoc.GetElement(stre)
MsgBox(Elllem.Name.ToString)
EndIf
Next
MsgBox(planView.Parameter(
BuiltInParameter.SHEET_CURRENT_REVISION).AsString)
MsgBox(planView.Parameter(
BuiltInParameter.SHEET_CURRENT_REVISION_DATE).AsString)
MsgBox(planView.Parameter(
BuiltInParameter.SHEET_CURRENT_REVISION_DESCRIPTION).AsString)
MsgBox(planView.SheetNumber.ToString)
MsgBox(planView.Name)
EndIf
Next
Best regards
Solved! Go to Solution.
Solved by Dollih. Go to Solution.