Confounding String to Array gotcha


Q: How can a seemingly empty array create user normals ???


A: It’s not empty. It’s so full it cannot display the string 🙂 I pasted in a string of 7558 characters that was a comma-separated list of the user normal vectors created by Modify > Component > Set User Normals > Polygon.

The “gotcha” is that String to Array appears empty when you paste in large strings.

n = Application.Dictionary.GetObject( "sphere.polymsh.ICETree.StringToArray" )

#print n.Parameters( "Value_string" ).Value
print len(n.Parameters( "Value_string" ).Value)

# 7558

2 thoughts on “Confounding String to Array gotcha

  1. So you’re saying there is no arbitrary limit to storage of ICE strings then? Or just that the limit for visualizing them in a textbox is smaller than the actual true limit?

    • I’m just saying that if you paste in a “long” string, the String to Array PPG cannot display it. I don’t know what the actual limit is…in this case I’m going to guess it is a PPG control limit.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s