I'm trying to remove some text in some grouped text fields, from a script located in the cards behavior script (I'm using the Levure framework).
Sample code:
Code: Select all
on openCard
local i = 0
start editing group "grpIcons" of card "preferences" of stack "main_window"
-- Clear preferences
repeat while i < 24
local tPreferenceName
local tPreferenceValue
local tPreferenceField
put "ICONS Custom" && i into tPreferenceName
put "fldCustom" & i into tPreferenceField
put tPreferenceValue into fld tPreferenceField of group "grpIcons" of card "preferences" of stack "main_window"
put i + 1 into i
end repeat
stop editing group "grpIcons" of card "preferences" of stack "main_window"
end openCard
I've tried leaving off the "of group "grpIcons" of card "preferences" of stack "main_window"" as well as just leaving off the "of group "grpIcons"", to no avail. The posted script works just fine without the objects being grouped (without the edit group calls obviously).
Where did I go wrong?
Thanks in advance for any assistance.