.NET

.NET

Reply
Valued Contributor
91 Posts
1 Kudo
Registered: ‎08-22-2013
Post 1 of 2
Accepted Solution

how to get the objectid of a line in a blockreference by mouse select?

189 Views, 1 Replies
03-10-2014 04:44 AM

how to get the objectid of a line in a blockreference by mouse select?

 

anybody done this? please give me some code. thanks.

Minimilist code:

Dim myDoc As Document = Application.DocumentManager.MdiActiveDocument
Dim myEd As Editor = myDoc.Editor
Dim myPEO As New PromptNestedEntityOptions("Select line in block:")
Dim myPER As PromptNestedEntityResult = myEd.GetNestedEntity(myPEO )
myPER .ObjectId

 This should return the object ID of the entity selected.

 

matt

Active Contributor
37 Posts
4 Kudos
Registered: ‎11-13-2006
Post 2 of 2

Re: how to get the objectid of a line in a blockreference by mouse select?

03-10-2014 09:14 AM in reply to: swaywood

Minimilist code:

Dim myDoc As Document = Application.DocumentManager.MdiActiveDocument
Dim myEd As Editor = myDoc.Editor
Dim myPEO As New PromptNestedEntityOptions("Select line in block:")
Dim myPER As PromptNestedEntityResult = myEd.GetNestedEntity(myPEO )
myPER .ObjectId

 This should return the object ID of the entity selected.

 

matt

matt worland
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post