Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Show only
|
Search instead for
Did you mean:
This page has been translated for your convenience with an automatic translation service. This is not an official translation and may contain errors and inaccurate translations. Autodesk does not warrant, either expressly or implied, the accuracy, reliability or completeness of the information translated by the machine translation service and will not be liable for damages or losses caused by the trust placed in the translation service.Translate
Dim acSSet As SelectionSet = acSSPrompt.Value
For Each acSSobj As SelectedObject In acSSet
If Not IsDBNull(acSSobj) Then
Dim acEnt As Entity = acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForWrite)
If Not IsDBNull(acEnt) Then
acEnt.ColorIndex = 9
Dim FetchObj As Object = acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForRead)
Dim myCircle As Circle
Dim pt As Point3d = myCircle.Center
End If
End If
Next
I am hitting my head against the wall. This is code from the .NET Developers Guide which changes the color of a circle.
I think I just about got it right. Is anyone willing to look at this and suggest a direction to go. Please.
I don't know whether this line
Dim FetchObj As Object = acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForRead)
would impact on this line
Dim acEnt As Entity = acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForWrite)
or why it is necessary.
This is code from the .NET Developers Guide which changes the color of a
circle.
{quote}
I think not. No code in any Autodesk publication is that broken.
I would go back and look at the example code you cite, and see what's
missing in your adaptation of it, because if the example code shows how to
do what you say it does, but you can't manage to adapt it, then the problem
is that you haven't gotten the prerquisites down first (a basic
understanding of the VB.NET language), and you shouldn't rely on folks here
to help you with that.
I would suggest taking a course in VB.NET or getting some basic training on
it, or using the self-learning tools at MSDN, before even thinking about
writing any AutoCAD code.
Few people here have the time or patience to offer this kind of tutoring,
and while people here can post example code that does what you're trying to
do, that isn't really going to help very much when it comes to learning the
basics of VB.NET.
--
http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD
Supporting AutoCAD 2000 through 2010
wrote in message news:6295432@discussion.autodesk.com...
Hi Guys and Gals,
Dim acSSet As SelectionSet = acSSPrompt.Value
For Each acSSobj As SelectedObject In acSSet
If Not IsDBNull(acSSobj) Then
Dim acEnt As Entity =
acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForWrite)
If Not IsDBNull(acEnt) Then
acEnt.ColorIndex = 9
Dim FetchObj As Object =
acTrans.GetObject(acSSobj.ObjectId, OpenMode.ForRead)
Dim myCircle As Circle
Dim pt As Point3d = myCircle.Center
End If
End If
Next
I am hitting my head against the wall. This is code from the .NET Developers
Guide which changes the color of a circle.
I think I just about got it right. Is anyone willing to look at this and
suggest a direction to go. Please.