马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?立即注册
×
- using System.Reflection;
- using Autodesk.AutoCAD.Runtime;
- using Autodesk.AutoCAD.ApplicationServices;
- using Autodesk.AutoCAD.DatabaseServices;
- using Autodesk.AutoCAD.EditorInput;
- using Exception = System.Exception;
- [assembly: CommandClass(typeof(AutoCAD_CSharp_plug_in35.MyCommands))]
- namespace AutoCAD_CSharp_plug_in35
- {
- public class MyCommands
- {
- [LispFunction("test", "MyLispFunctionLocal")]
- public void MyLispFunction(ResultBuffer args) // This method can have any name
- {
- if (args != null)
- {
- TypedValue[] values = args.AsArray();
- if (values .Length == 1 && values[0].TypeCode == (int)LispDataType .ObjectId )
- {
- Document doc = Application.DocumentManager.MdiActiveDocument;
- Editor ed = doc.Editor;
- Database db = doc.Database;
- Transaction tr = db.TransactionManager.StartTransaction();
- using (tr)
- {
- try
- {
- var id =(ObjectId ) values[0].Value;
- var obj = (DBObject) id.GetObject(OpenMode.ForRead);
- foreach (MemberInfo objMemberInfo in obj.GetType().GetMembers())
- {
- ed.WriteMessage("\n" + objMemberInfo.Name.ToString());
- }
- tr.Commit();
- }
- catch (Exception)
- {
- throw;
- }
- }
- }
- }
- }
- }
- }
命令: NETLOAD
命令: (test (entlast))
get_StartPoint
set_StartPoint
get_EndPoint
set_EndPoint
get_Thickness
set_Thickness
get_Normal
set_Normal
get_Delta
get_Angle
get_Length
get_Closed
get_IsPeriodic
get_StartParam
get_EndParam
GetPointAtParameter
GetParameterAtPoint
GetDistanceAtParameter
GetParameterAtDistance
GetDistAtPoint
GetPointAtDist
GetFirstDerivative
GetFirstDerivative
GetSecondDerivative
GetSecondDerivative
GetClosestPointTo
GetClosestPointTo
GetOrthoProjectedCurve
GetProjectedCurve
GetOffsetCurves
GetOffsetCurvesGivenPlaneNormal
get_Spline
GetSplitCurves
GetSplitCurves
Extend
Extend
get_Area
ReverseCurve
GetGeCurve
GetGeCurve
SetFromGeCurve
SetFromGeCurve
SetFromGeCurve
SetFromGeCurve
set_MaterialMapper
get_BlockName
get_ForceAnnoAllVisible
set_ForceAnnoAllVisible
get_VisualStyleId
set_VisualStyleId
get_FaceStyleId
set_FaceStyleId
get_EdgeStyleId
set_EdgeStyleId
JoinEntity
JoinEntities
get_BlockId
get_Color
set_Color
get_ColorIndex
set_ColorIndex
get_EntityColor
get_Transparency
set_Transparency
get_PlotStyleName
set_PlotStyleName
get_PlotStyleNameId
set_PlotStyleNameId
get_Layer
set_Layer
get_LayerId
set_LayerId
SetLayerId
get_Linetype
set_Linetype
get_LinetypeId
set_LinetypeId
get_LinetypeScale
set_LinetypeScale
get_Visible
set_Visible
get_LineWeight
set_LineWeight
get_CollisionType
SetPropertiesFrom
get_IsPlanar
GetPlane
get_Ecs
get_GeometricExtents
AddSubentityPaths
DeleteSubentityPaths
TransformSubentityPathsBy
GetGripPointsAtSubentityPath
MoveGripPointsAtSubentityPaths
GetSubentityGeometricExtents
GetSubentityPathsAtGraphicsMarker
GetSubentityPathsAtGraphicsMarker
GetGraphicsMarkersAtSubentityPathIntPtr
Highlight
Highlight
Unhighlight
Unhighlight
PushHighlight
PopHighlight
HighlightState
GetObjectSnapPoints
GetObjectSnapPoints
IsContentSnappable
GetGripPoints
GetGripPoints
MoveGripPointsAt
MoveGripPointsAt
GetStretchPoints
MoveStretchPointsAt
IntersectWith
IntersectWith
IntersectWith
IntersectWith
BoundingBoxIntersectWith
BoundingBoxIntersectWith
BoundingBoxIntersectWith
BoundingBoxIntersectWith
List
TransformBy
GetTransformedCopy
GetSubentity
Explode
RecordGraphicsModified
Draw
SaveAs
get_CompoundObjectTransform
SetDatabaseDefaults
SetDatabaseDefaults
get_CloneMeForDragging
SetDragStatus
SetGripStatus
SetSubentityGripStatus
get_Hyperlinks
get_CastShadows
set_CastShadows
get_ReceiveShadows
set_ReceiveShadows
get_Material
set_Material
get_MaterialId
set_MaterialId
get_MaterialMapper
SetPaperOrientation
ApplyPaperOrientationTransform
SupportsCollection
HasContext
AddContext
RemoveContext
GetEventExtender
add_Cancelled
remove_Cancelled
add_Copied
remove_Copied
add_Erased
remove_Erased
add_Goodbye
remove_Goodbye
add_OpenedForModify
remove_OpenedForModify
add_Modified
remove_Modified
add_SubObjectModified
remove_SubObjectModified
add_ModifyUndone
remove_ModifyUndone
add_ModifiedXData
remove_ModifiedXData
add_Unappended
remove_Unappended
add_Reappended
remove_Reappended
add_ObjectClosed
remove_ObjectClosed
GetParameterInterface
get_IsPersistent
get_Id
get_ObjectId
get_OwnerId
set_OwnerId
get_Handle
get_Database
DeepClone
WblockClone
DecomposeForSave
get_Drawable
CreateExtensionDictionary
get_ExtensionDictionary
ReleaseExtensionDictionary
UpgradeOpen
UpgradeFromNotify
DowngradeOpen
DowngradeToNotify
Cancel
Close
CloseAndPage
Erase
Erase
HandOverTo
SwapIdWith
SwapReferences
Audit
DwgIn
DwgOut
DxfIn
DxfOut
get_MergeStyle
set_MergeStyle
get_XData
set_XData
XDataTransformBy
GetXDataForApplication
get_IsEraseStatusToggled
get_IsErased
get_IsReadEnabled
get_IsWriteEnabled
get_IsNotifyEnabled
get_IsModified
get_IsModifiedXData
get_IsModifiedGraphics
get_IsNewObject
get_IsNotifying
get_IsUndoing
get_IsCancelling
get_IsReallyClosing
get_IsTransactionResident
get_IsAProxy
DisableUndoRecording
get_UndoFiler
ApplyPartialUndo
HasPersistentReactor
GetReactors
GetTransientReactors
GetPersistentReactorIds
SetObjectIdsInFlux
get_IsObjectIdsInFlux
get_HasSaveVersionOverride
set_HasSaveVersionOverride
GetObjectSaveVersion
GetObjectSaveVersion
get_ObjectBirthVersion
get_ClassID
get_AcadObject
GetField
GetField
SetField
SetField
get_HasFields
RemoveField
RemoveField
RemoveField
get_Annotative
set_Annotative
SetFromStyle
ResetScaleDependentProperties
get_PaperOrientation
SetAttributes
WorldDraw
ViewportDraw
ViewportDrawLogicalFlags
get_DrawableType
get_Bounds
get_DrawStream
set_DrawStream
X
QueryX
GetRXClass
CompareTo
Clone
CopyFrom
get_UnmanagedObject
get_IsDisposed
get_AutoDelete
Equals
GetHashCode
Dispose
GetLifetimeService
InitializeLifetimeService
CreateObjRef
ToString
GetType
.ctor
.ctor
Length
Angle
Delta
Normal
Thickness
EndPoint
StartPoint
Area
Spline
EndParam
StartParam
IsPeriodic
Closed
EdgeStyleId
FaceStyleId
VisualStyleId
ForceAnnoAllVisible
BlockName
MaterialMapper
MaterialId
Material
ReceiveShadows
CastShadows
Hyperlinks
CloneMeForDragging
CompoundObjectTransform
GeometricExtents
Ecs
IsPlanar
CollisionType
LineWeight
Visible
LinetypeScale
LinetypeId
Linetype
LayerId
Layer
PlotStyleNameId
PlotStyleName
Transparency
EntityColor
ColorIndex
Color
BlockId
PaperOrientation
Annotative
HasFields
AcadObject
ClassID
ObjectBirthVersion
HasSaveVersionOverride
IsObjectIdsInFlux
UndoFiler
IsAProxy
IsTransactionResident
IsReallyClosing
IsCancelling
IsUndoing
IsNotifying
IsNewObject
IsModifiedGraphics
IsModifiedXData
IsModified
IsNotifyEnabled
IsWriteEnabled
IsReadEnabled
IsErased
IsEraseStatusToggled
XData
MergeStyle
ExtensionDictionary
Drawable
Database
Handle
OwnerId
ObjectId
Id
IsPersistent
DrawStream
Bounds
DrawableType
AutoDelete
IsDisposed
UnmanagedObject
ObjectClosed
Reappended
Unappended
ModifiedXData
ModifyUndone
SubObjectModified
Modified
OpenedForModify
Goodbye
Erased
Copied
Cancelled |