Creating UCS from line
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Can someone help me to create a UCS from a given line (should ultimately only use the x-direction so it is subordinate to how it is twisted around the x-axis.)
I have a problem switching to a new UCS.
I have a given line, for it I find the starting point and the end point,
then I find a point perpendicular to the line from the starting point,
I have tried 2 methods:
the first was a vector calculation in vba,
the second used thisdrawing.utilitu.polarpunkt.
Then i used thisdrawing.ucs.add…..
With both calculations, AutoCAD came up with an error that the 3 points do not form a right angle.
I have tried to calculate both as points and as vectors
I have then had the program draw lines between the points.
It is now possible to switch UCS from the command line by pointing to the 3 points.
I therefore tried to use Sendcommand.
There is no error using this metode, but the generated UCS is completely wrong.
What do i do wrong 😞