Tables do no have a rotation angle. I can find the insert point, but there is no other point to make an angle calculation with.
(setq objTable (vlax-ename->vla-object (car (entsel))))
(vlax-dump-object objTable T)
You may use vla-TransformBy with the UCS's transformation matrix.
To get the UCS transformation matrix it mus be a NAMED UCS.
This is a very simple example, it supposes your UCS is named previously:
(defun align-table (/ table mtrans)
(setq table (vlax-ename->vla-object
(car (entsel "\nSelect Table:"))))
(vla-TransformBy table mtrans))
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register
Start with some of our most frequented solutions to get help installing your software.