VBScript question

Discussions concerning programming of SOFTIMAGE©
iamVFX
Posts: 697
Joined: 24 Sep 2010, 16:28

VBScript question

Post by iamVFX » 13 Mar 2011, 11:46

How can I get a value from attribute of the object? For example I have "pointcloud" and I need get ".NbPoints" attribute and set it value to variable N. How can I do that? I will be glad to get any useful links or answers, thanks!

User avatar
xsisupport
Posts: 713
Joined: 09 Jun 2009, 09:02
Location: Montreal Canada

Re: VBScript question

Post by xsisupport » 14 Mar 2011, 10:03

You can get attributes with the ICEAttribute property.
NbPoints is read only.

Code: Select all

set oAttribute = Selection(0).ActivePrimitive.Geometry.ICEAttributes("NbPoints")

LogMessage "Name: " & oAttribute.Name 
LogMessage "Readonly: " & oAttribute.IsReadonly
// Steve Blair
// "You're not a runner, you're just a guy who runs" -- my wife
//
// My Blogs: Arnold | Softimage

iamVFX
Posts: 697
Joined: 24 Sep 2010, 16:28

Re: VBScript question

Post by iamVFX » 14 Mar 2011, 14:52

Thank you!