Get infos like "list" command

Get infos like "list" command

xaotix
Enthusiast Enthusiast
1,041 Views
4 Replies
Message 1 of 5

Get infos like "list" command

xaotix
Enthusiast
Enthusiast

Hello.

I'm struggling trying to discover a method to retain the properties showed on "list" command when I select a custom object.

 

1) how is the way to interact with those objects

2) is there a method to extract those properties?

 

 

I'm trying using 

t.GetProperties(flags)

or 

ObjectPropertyManagerPropertyUtility.GetIUnknownFromObjectId(id);

 

but without success. It only returns generic properties.

 

 

0 Likes
1,042 Views
4 Replies
Replies (4)
Message 2 of 5

essam-salah
Advisor
Advisor

Hi @xaotix 

what objects you dealing with ?

0 Likes
Message 3 of 5

essam-salah
Advisor
Advisor

Hi @xaotix 

you can access whatever property you want depends on the object you dealing with, properties like: Area, Length, Color, Coordinates, StartPoint, EndPoint ...

0 Likes
Message 4 of 5

xaotix
Enthusiast
Enthusiast

hello

 

It's a custom object "Steel&Graphics Profile 3D" TEC_PROFILE3D

I want to read the properties that is showed when I use "list" command:

 

Steel&Graphics Profile 3D
-------------------------
Profile Name:FERRO 23.2 SAE1020
PtIns   :(1.070072E+007,-36775.405908,11862.885879)
PtEnd   :(1.070354E+007,-34745.090669,11781.508431)
Rotation:0.000000
Coord.  :2
Length  :3475.74
DirX    :1.000,0.000,0.000
DirY    :0.000,1.000,0.000
-------------------------
0#PROFILE#TRB=11.6#CAT=7#PESO=3.3#H=23.2#SUP1=0.07#PROFILO=FERRO 23.2 
SAE1020#PTENDID=#PTINSID=#TRB1=11.6#B=23.2#
7#VER1#NUMPT=2#PT1=10700785.6432,-36728.6748,11861.0128#PT2=10703475.7589,-34791
.8217,11783.3815#
7#VER2#VNINI=0,0,0,0#VNEND=0,0,0,0#VKINI=0,0,0,0#VKEND=0,0,0,0#
7#VER3#CBETA=0.7000,0.7000,0.5000#LF=200#CAR=1#INTER=1#
-------------------------
 B    :23.20
 H    :23.20
 Trb  :11.60
 Trb1 :11.60
-------------------------
List Profile ID:
Internal ID:579D0621B1FF4235A7CA31F1FF86BEF2
Owner    ID:
Mark User  :
Pos. User  :
-------------------------
StrElem   :0
MaxFreeLen:0.000000
GuidElem  :
CodeElem  :0
-------------------------
Section 'PROFILEDATA' contain:
MAT_PRO=CIVIL 350
TRA_PEZ=C
COD_MAG=10130026
NOT_PEZ=CINZA RAL 7004
TINSPROF=
-------------------------
Internal data:
                  TEC_PROFILE3D  Layer: "0-CONTRAVENTOS"
                            Space: Model space
                   Color: 7 (white)    Linetype: "BYLAYER"
                   Handle = 96a514

 

 

but, with my attempts using some AutoCAD.Net methods, I only get something like:

 

Propriedades de PromptEntityResult:

 - RXObject -

 - Drawable -
Bounds = 
DrawableType = Geometry
Id = (140689928654640)
IsPersistent = True

 - DBObject -
PaperOrientation = NotApplicable
Annotative = NotApplicable
HasFields = False
AcadObject = System.__ComObject
ClassID = 9c4f54dc-58d1-4914-917d-ddc4fb1aba23
ObjectBirthVersion = Current,Release6
HasSaveVersionOverride = False
IsObjectIdsInFlux = False
UndoFiler = 
IsAProxy = False
IsTransactionResident = True
IsReallyClosing = False
IsCancelling = False
IsUndoing = False
IsNotifying = False
IsNewObject = False
IsModifiedGraphics = False
IsModifiedXData = False
IsModified = False
IsNotifyEnabled = False
IsWriteEnabled = False
IsReadEnabled = True
IsErased = False
IsEraseStatusToggled = False
XData = 
MergeStyle = Ignore
ExtensionDictionary = (0)
Drawable = Autodesk.AutoCAD.DatabaseServices.ImpEntity
Database = Autodesk.AutoCAD.DatabaseServices.Database
Handle = 96A513
OwnerId = (140689934412272)
ObjectId = (140689928654640)
Id = (140689928654640)
IsPersistent = True

 - Entity -
EdgeStyleId = (0)
FaceStyleId = (0)
VisualStyleId = (0)
ForceAnnoAllVisible = True
BlockName = *Model_Space
MaterialMapper = 
MaterialId = (140689934412736)
Material = ByLayer
ReceiveShadows = True
CastShadows = True
Hyperlinks = Autodesk.AutoCAD.DatabaseServices.HyperLinkCollection
CloneMeForDragging = True
CompoundObjectTransformException has been thrown by the target of an invocation.
GeometricExtentsException has been thrown by the target of an invocation.
Ecs = ((-0.601558979889493,-0.0037107775398895,-0.798819769312429,10703435.9763539),(-0.798828388149991,0.00279440688964804,0.601552489460249,-36795.7472774908),(0,0.999989210651887,-0.00464527499890597,11792.5577960653),(0,0,0,1))
IsPlanar = False
CollisionType = Solid
LineWeight = ByLayer
Visible = True
LinetypeScale = 1
LinetypeId = (140689934412112)
Linetype = ByLayer
LayerId = (140689931547904)
Layer = 0-CONTRAVENTOS
PlotStyleNameId = ((0),PlotStyleNameByLayer)
PlotStyleName = Color_7
Transparency = (0)
EntityColor = Autodesk.AutoCAD.Colors.EntityColor
ColorIndex = 7
Color = white
BlockId = (140689934412272)

 - ImpEntity -	Color = System.__ComObject
	Layer = 0-CONTRAVENTOS
	Linetype = ByLayer
	Linetype scale = 1
	Plot style = Color_7
	Lineweight = -1
	Hyperlink = System.__ComObject
	Transparency = ByLayer
	Material = ByLayer


Propriedades padrao

	EdgeStyleId: (0)
	FaceStyleId: (0)
	VisualStyleId: (0)
	ForceAnnoAllVisible: True
	BlockName: *Model_Space
	MaterialMapper: 
	MaterialId: (140689934412736)
	Material: ByLayer
	ReceiveShadows: True
	CastShadows: True
	Hyperlinks: Autodesk.AutoCAD.DatabaseServices.HyperLinkCollection
	CloneMeForDragging: True
	CompoundObjectTransform: Erro ao tentar ler: Exception has been thrown by the target of an invocation.
	CompoundObjectTransform: 
	GeometricExtents: Erro ao tentar ler: Exception has been thrown by the target of an invocation.
	GeometricExtents: 
	Ecs: ((-0.601558979889493,-0.0037107775398895,-0.798819769312429,10703435.9763539),(-0.798828388149991,0.00279440688964804,0.601552489460249,-36795.7472774908),(0,0.999989210651887,-0.00464527499890597,11792.5577960653),(0,0,0,1))
	IsPlanar: False
	CollisionType: Solid
	LineWeight: ByLayer
	Visible: True
	LinetypeScale: 1
	LinetypeId: (140689934412112)
	Linetype: ByLayer
	LayerId: (140689931547904)
	Layer: 0-CONTRAVENTOS
	PlotStyleNameId: ((0),PlotStyleNameByLayer)
	PlotStyleName: Color_7
	Transparency: (0)
	EntityColor: Autodesk.AutoCAD.Colors.EntityColor
	ColorIndex: 7
	Color: white
	BlockId: (140689934412272)
	PaperOrientation: NotApplicable
	Annotative: NotApplicable
	HasFields: False
	AcadObject: System.__ComObject
	ClassID: 9c4f54dc-58d1-4914-917d-ddc4fb1aba23
	ObjectBirthVersion: Current,Release6
	HasSaveVersionOverride: False
	IsObjectIdsInFlux: False
	UndoFiler: 
	IsAProxy: False
	IsTransactionResident: False
	IsReallyClosing: True
	IsCancelling: False
	IsUndoing: False
	IsNotifying: False
	IsNewObject: False
	IsModifiedGraphics: False
	IsModifiedXData: False
	IsModified: False
	IsNotifyEnabled: False
	IsWriteEnabled: False
	IsReadEnabled: True
	IsErased: False
	IsEraseStatusToggled: False
	XData: 
	MergeStyle: Ignore
	ExtensionDictionary: (0)
	Drawable: Autodesk.AutoCAD.DatabaseServices.ImpEntity
	Database: Autodesk.AutoCAD.DatabaseServices.Database
	Handle: 96A513
	OwnerId: (140689934412272)
	ObjectId: (140689928654640)
	Id: (140689928654640)
	IsPersistent: True
	Bounds: 
	DrawableType: Geometry
	AutoDelete: False
	IsDisposed: False
	UnmanagedObject: 1852315856

 

 

 

0 Likes
Message 5 of 5

8XXXNNJH7KT6
Autodesk
Autodesk
The LIST command calls the list() function on the C++ class for the entity which in turn calls the subList() method that the entity's class implements. So, it is possible that the LIST command can show information that isn't directly available as entity properties.
0 Likes