# Symbol scale factors

## Recommended Posts

Hi VW-User,

greetings.

Unfortunately, I do not have any experience with scripts yet.

I have an idea, but do not know if it is possible to achieve.

Often I use symbols with 1 x 1 x 1 cm, in plan I scale these

symbol-instances to my needed size.

The plan was to get the scaled size into worksheet-reports,

but in worksheets, the symbols are reported without my custom scale-factors.

All scaled symbols are 1 x 1 x 1 cm in my reporting.

For symbols as objects, there are no formulas or other functions to get directly

information into worksheets.

Now I want to know if it is possible to get the “scale factors” for x, y and z (each

separately as own script) with scripts, so that I can use it with “run script” in my

worksheets to get accurate reports.

/ / /

It would be great, if we can get functions and formulas for symbol reporting

in worksheets directly, without the need of a script.

Greetings from Germany

Tobi

##### Link to comment

=OBJECTDATA('OBJECT VARIABLE', 102)

This will give you the X scale factor for a scaled symbol.  103 will give you Y,  104 will give you Z.

101 is supposed to return the scaling type (none, Symmetric, Asymetric, probably as 0, 1,2) but in my quick test is is returning something odd instead.

##### Link to comment

ObjVar 101 has an integer value of 1=None, 2=Symmetric, or 3=Asymmetric.

ObjVars 102-104 are the XY&Z scaling factors (Real).

If ObjVar 101 = 1 (None) then the XY&Z scaling factors = 1.

If ObjVar 101 = 2 (Symmetric) then the Y&Z scaling factors = the X Scaling factor.

Only when ObjVar 101 = 3 (Asymmetric) do you need to read all two, or three, scaling factors. (X&Y for 2D Symbols, and XY&Z for 3D symbols).

Raymond

##### Link to comment

@MullinRJDid you actually test the return from 101?

I did and I do not get the expected 1, 2, 3.  I get a large (>1000000) positive or negative integer.

Wondering if I did something wrong or if it is broken and needs a bug filed.

##### Link to comment

Hey @Pat Stanford

Did you use GetObjectVariableInt(H, 101), not GetObjectVariableReal(H, 101)? I use it in Reshaper and it's worked for years. I didn't test today, but Reshaper is still working for symbols so I assume these commands are still working as advertised.

All the best,

Raymond

##### Link to comment

I used the worksheet equivalent and get funky numbers. Positive and negative hundreds of millions. If it weren't for the negative I would think it was returning the LongInt equivalent of a Handle.

=OBJECTDATA('OBJECT VARIABLE', 101)

##### Link to comment

Hi and Mercy beaucoup!

I will try it out in the comming days!

Greetings from Germany

Tobi

##### Link to comment

Hi Pat,

is there an overview for all 'object variables'?

Greetings

Tobi

##### Link to comment

Hi,

tried …

… and works!

Perfect.

This solution means a lot for quantity take-offs of "simple" 3D geometries!

Greetings and many many Thnx

Tobi

##### Link to comment

Hi,

I found a overview here:

… but the "scale factors" are not listed there.

It seems the overview is not really complete!

Greetings

Tobi

##### Link to comment

Interesting that the online Appendix G is so much shorter than the installed version.

In you Applications folder Vectorworks 2021:VWHelp:Script Reference:ScriptFunctionReference.html you will find "All" of the Vectorscript documentation.

Click on Additional References at the upper left and then on Script Appendix.  There is a fuller version of Appendix G there.

##### Link to comment
On 11/3/2022 at 6:10 PM, Pat Stanford said:

I used the worksheet equivalent and get funky numbers. Positive and negative hundreds of millions. If it weren't for the negative I would think it was returning the LongInt equivalent of a Handle.

=OBJECTDATA('OBJECT VARIABLE', 101)

That's what I like about you @Pat Stanford, you always show me something I wasn't expecting. After looking at it your way, I'd agree  —  it's a BUG. It should be returning a very small integer.

Raymond

## 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.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

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

×
×

• KBASE
• #### MARIONETTE

×
• Create New...