[JW Lua] More Page Text Fun
Jari Williamsson
jari.williamsson at mailbox.swipnet.se
Tue Oct 22 15:56:57 CEST 2013
On 2013-10-22 12:20, Dave Foster wrote:
> it only deletes a couple of the objects. Run again, it
> deletes another etc. Am I missing something either in updating the
> collection, or deleting in a for loop?
Always delete items in a collection retrieved by Finale BACKWARDS, since
each data object is just loosely linked to Finale by numbers/indexes.
For example:
texts = finale.FCPageTexts()
texts:LoadAll()
for i = texts.Count-1, 0, -1 do
texts:GetItemAt(i):DeleteData()
end
> However, when selecting the text and (in Finale itself) choosing
> Edit Frame Attributes, the horizontal attribute is correctly set
> at "Center" - and clicking OK then moves it to the centre on the
> page. So, it would seem to be set correctly, there's just
> something not updating. Any ideas?
That sounds like a bug on my end. My guess is that I don't initialize
the FCTextBlock correctly when it's created. I'll look into that.
Best regards,
Jari Williamsson
More information about the JWLua
mailing list