<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    Jari,<br>
    <br>
    I have discovered a weird page break bug in JW Lua.<br>
    Take the Finale default document or any empty document that has a
    score and a part. Then run the simple script below. Make sure the
    measure number you enter (the "8" below) is a measure where a new
    system starts in the score. It doesn't matter if the new system also
    starts in the part.<br>
    <br>
    The script just adds a page break in measure 8 in the part.<br>
    Now click on undo and redo  ... and ups, the page break also appears
    in  the score and leads to the systems starting with measure 8
    vanishing!<br>
    Here is a screencam video:  <a class="moz-txt-link-freetext" href="https://youtu.be/lEZqDX0i8yM">https://youtu.be/lEZqDX0i8yM</a><br>
    <br>
    local parts=finale.FCParts()<br>
    parts:LoadAll()<br>
    for p in each(parts) do<br>
        p:SwitchTo()<br>
            if (p.ID>0) then --if this is a part<br>
                local meas=finale.FCMeasure()<br>
                meas:Load(8) --this must be a measure number where a new
    system starts in the score<br>
                meas.PageBreak=true<br>
                meas:Save()<br>
            end<br>
        p:SwitchBack()<br>
    end<br>
    <br>
    Maybe it has something to do with our email conversation from the
    2017/09/11 about "are FCMeasure properties part-dependent or
    global"? Anyone any ideas on this?<br>
    <br>
    Jan<br>
  </body>
</html>