Loki
05-06-2008, 04:24 PM
I have a trouble about a simple code...
Here an example wrote only to explain my question:
SelectObj "Piero*"
for each polymsh in Application.Selection
LogMessage polymsh
LogMessage polymsh.Name
LogMessage polymsh.Model
set pModelName = polymsh
set pName = polymsh.Name
next
If i run it, XSI give me these lines:
'INFO : Piero_Weight.Piero
'INFO : Piero
'INFO : Piero_Weight
'INFO : Piero
'ERROR : Object required: '[string: "Piero"]' - [line 7]
Why polymsh.Name is valid for a LogMessage, but invalid for a simple set string?
Where I wrong?
Here an example wrote only to explain my question:
SelectObj "Piero*"
for each polymsh in Application.Selection
LogMessage polymsh
LogMessage polymsh.Name
LogMessage polymsh.Model
set pModelName = polymsh
set pName = polymsh.Name
next
If i run it, XSI give me these lines:
'INFO : Piero_Weight.Piero
'INFO : Piero
'INFO : Piero_Weight
'INFO : Piero
'ERROR : Object required: '[string: "Piero"]' - [line 7]
Why polymsh.Name is valid for a LogMessage, but invalid for a simple set string?
Where I wrong?