Orient rectangular to line direction

Dear My friends
I want to orient rectangular from top right point to this line direction.
please help me if you can.

Orient rec to line.gh (3.2 KB)
Orient rec to line.3dm (57.0 KB)

You’re aware that if you simply rotate you won’t get the second image, right?
You need move then rotate

Yes i want move and then rotate but its necessary that move from the point in top right side of rectangular.

fast way is to just recreate the rectangle (up) but the series of points is lost (if it interests you)
long way is to reorient and keep the point series (down)

*also: it’s good to internalize your geometry so as not to have to upload a .3dm file (have a look here)

orient.gh (14.2 KB)

1 Like

Thank you very much