Hi …
How do you get the DS Entity object from it’s index? - As provided by the Published Item.
1 = Alignment, 2 = Surface
This script is returning the index values (1 and 8), I need to get the Entity Type by using the index that’s provided…
Thx for your patience…
import sys
import clr
clr.AddReference('AeccDbMgd')
clr.AddReference('AeccDataShortcutMgd')
from Autodesk.Civil.DataShortcuts import *
vals = DataShortcuts.CreateDataShortcutManager(True)
dsm = vals[0]
c = dsm.GetPublishedItemsCount()
o = []
for i in range(c):
p = dsm.GetPublishedItemAt(i)
if not p.IsBroken:
o.append([p.Name , p.DSEntityType])
OUT = o
