<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
When deleting from a collection class always use eachbackwards()
instead of each() and never save the collection afterwards.<br>
This code should work:<br>
<div class="moz-cite-prefix"><br>
</div>
<blockquote type="cite"
cite="mid:CAACncesn9eMKZ+U_E7K6zoA=rmL4fBFVbLCf3Qu5HHyG0oucaw@mail.gmail.com">
<div>if finenv.FinaleVersion >= 2011 then</div>
<div><br>
</div>
<div> groups = finale.FCGroups(0, 0)</div>
<div> groups:LoadAll()</div>
<div><br>
</div>
<div> for g in each<b>backwards</b>(groups) do</div>
<div><br>
</div>
<div> if g:GetItemID() == 18 then</div>
<div><br>
</div>
<div> g:DeleteData()</div>
<div><br>
</div>
<div> end</div>
<div> end</div>
end</blockquote>
<br>
<br>
Jan<br>
</body>
</html>