Difficulty understanding UCS behavior.

Difficulty understanding UCS behavior.

Anonymous
Not applicable
245 Views
1 Reply
Message 1 of 2

Difficulty understanding UCS behavior.

Anonymous
Not applicable
Here is what I did (See code Below)

On the bottom when I look at the values of .Origin(0 to 2) it gives me
(-450,-350,1450)

But nothing appends when I change the origin 0,0,0

Is there something missing in my code?

Thanks.

basePt(0) = Section
basePt(1) = ptCad(0)
basePt(2) = ptCad(1)
Xaxis(0) = basePt(0)
Xaxis(1) = basePt(1) + 10#
Xaxis(2) = basePt(2)

Yaxis(0) = basePt(0)
Yaxis(1) = basePt(1)
Yaxis(2) = basePt(2) + 10#

Set colUcs = ThisDrawing.UserCoordinateSystems
Set Ucs = colUcs.Add(basePt, Xaxis, Yaxis, "2D_" & Section)
Org = Ucs.origin(0)
Org = Ucs.origin(1)
Org = Ucs.origin(2)

ptCad(0) = 0
ptCad(1) = 0
ptCad(2) = 0
Ucs.origin = ptCad
0 Likes
246 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
From .ActiveUCS property in VBA online help...

"Changes made to the current active UCS will become visible only after that
UCS is reset as the active UCS. To reset the active UCS, simply call this
property with the updated UCS object."

Try:

> Ucs.origin = ptCad
Thisdrawing.ActiveUCS = Ucs

Good luck,

James
0 Likes