Jump to content
  • 0
Russell Bird

Getting dimensions of an extruded shape - returned values are wrong

Question

Hello,

 

I'm not very experienced in drawing stuff in VectorWorks, but I've run into a problem which I'm sure is a mistake on my part.  Basically I draw a 2d square and set X to 100 and Y to 100, then I extrude the shape by 100.  I have then written a script which looks at the resulting cube and should return me the dims i.e. 100 x 100 x 100.  Instead, what happens is the length dim returns 100 as expected, but I get varying other values for the other 2 dims, 135 and 155.

 

I'm using vs.HLength, HWidth and HHeight to retrieve these values in the script and am a bit stumped by it.

 

Does anyone know what I'm doing wrong here?

 

Russell

Share this post


Link to post

2 answers to this question

Recommended Posts

  • 0

Is the cube rotated?  If so, then HWidth will return the width of the object at it's widest point on the X axis (like a bounding box), HHeight will do the same on the Y axis and HLength will do the same on the Z axis.

 

 

  • Like 1

Share this post


Link to post
  • 0

Hi, yes I think you are right.

 

I found a way around the problem by temporarily assigning a name, which then allows me to access the object in script using vs.LengthN, etc..  Seems to work, so it'll do for now.  I just thought it would be easier to access the object properties once selected, but guess not.

 

Thanks

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


 

7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114

 

© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

×
×
  • Create New...