
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I'll just start this out with this... I'm still really new to VB.Net in general, and very new from a "lets use this to do stuff in ACAD" standpoint. Google and the search function here have left me empty handed.
I am trying to get a point from the user, then use and manipulate the X and Y values to draw lines based on those manipulated values. I have gotten as far as the code below, and I'm totally lost when it comes to the syntax of reading and manipulating point values.
How would I turn the code example into something that:
-accepts a point input from user
-adds a variable to the X dimension to create a new point
-draws a line between these 2 points
The project is a bit more complicated than that, but sample code doing what is described above would get me pointed in the right direction.
Thanks in advance!
-Mitch
PS. This is for Mechanical Desktop (ACAD 2000)
Imports AutoCAD Private Sub BendLineButton_Click(sender As Object, e As EventArgs) Handles BendLineButton.Click Dim AcadApp As AcadApplication Try AcadApp = GetObject(, "AutoCAD.Application") Threading.Thread.Sleep(500) Catch ex As Exception AcadApp = CreateObject("AutoCAD.Application") End Try Dim acCurDoc As AcadDocument = AcadApp.ActiveDocument acCurDoc.Utility.Prompt("Select start point for bend lines.") Dim startpoint As AcadPoint = acCurDoc.Utility.GetPoint() 'Do Stuff, magical stuff, right here. End Sub
Solved! Go to Solution.