Jump to content
Sign in to follow this  
NeonClear

Dimension Input to String

Recommended Posts

I'm working on a marionette script that can do the following

  • Take dimension inputs.
  • Make a shape base on those inputs.
  • Make a text box next to the shape with the dimensions and other specifications.

I'm having trouble converting the dimension value into a string. Does anybody know of an easy way to do this?

Here's what I've tried so far. I've attempted to make a node for VS.Num2StrF but I'm not having any luck. If I hard code the value directly into the function it works.

vs.Num2StrF(12.000000000000002)

If I try to pass a variable, then it doesn't work. Am I making a simple mistake?

vs.Num2StrF(self.Params.dim.value)

Edited by NeonClear

Share this post


Link to post

Also, the nodes in the "Text" category should already convert the values to strings before creating the text objects, if you plan to use those.

Share this post


Link to post

Just to follow up - I think the issue with your node is only that you included "SetListAbsorb()".

When I took that out, your node ran for me.

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
Reply to this topic...

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

Sign in to follow this  

 

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