Copy link to clipboard
Copied
Creating a check box anchored in a text frame systematically ends with a crash in ID v16.2.1.
Does anyone here experience the same issue?
app.select( app.selection[0].paragraphs[0].insertionPoints[-2] );
app.selection[0].checkBoxes.add();
If you change checkBoxes.add() with textBoxes.add(), the script runs perfectly.
Confirmed (Windows 10).
Please submit a bug report at UserVoice (https://indesign.uservoice.com)
Hi zeRafio,
also confirmed from my side with this code:
var doc = app.documents.add();
var newTextFrame =
doc.textFrames.add
(
{
geometricBounds : [0,0,"100mm","100mm"]
}
);
newTextFrame.insertionPoints[0].checkBoxes.add();
Wheras this one is working:
var doc = app.documents.add();
var newTextFrame =
doc.textFrames.add
(
{
geometricBounds : [0,0,"100mm","100mm"]
}
);
var newCheckBox =
newTextFrame.parentPage.checkBoxes.add();
newCheckBox.anchoredObjectSettings.insertAnchoredObjec
...
Copy link to clipboard
Copied
Confirmed (Windows 10).
Please submit a bug report at UserVoice (https://indesign.uservoice.com)
Copy link to clipboard
Copied
Hi zeRafio,
also confirmed from my side with this code:
var doc = app.documents.add();
var newTextFrame =
doc.textFrames.add
(
{
geometricBounds : [0,0,"100mm","100mm"]
}
);
newTextFrame.insertionPoints[0].checkBoxes.add();
Wheras this one is working:
var doc = app.documents.add();
var newTextFrame =
doc.textFrames.add
(
{
geometricBounds : [0,0,"100mm","100mm"]
}
);
var newCheckBox =
newTextFrame.parentPage.checkBoxes.add();
newCheckBox.anchoredObjectSettings.insertAnchoredObject
(
newTextFrame.insertionPoints[0] ,
AnchorPosition.INLINE_POSITION
);
Regards,
Uwe Laubender
( ACP )
Copy link to clipboard
Copied
Very nice workaround, Uwe.
Copy link to clipboard
Copied
Bçonjour Uwe,
I was on the same pah for the workarround…
For those who, like me, are using Applescript, here is the code following your example:
tell application id "InDn"
set theDoc to make document
set theFrame to make text frame at theDoc with properties {geometric bounds:{0, 0, 100, 100}}
set theSwitch to make check box at parent page of theFrame
insert anchored object anchored object settings of theSwitch story offset insertion point 1 of theFrame anchored position inline position
end tell
😉
Copy link to clipboard
Copied
Bonjour Peter,
Bug report is posted on uservoice.
Thank you to you both.
Copy link to clipboard
Copied
Hi Peter,
I also tested and can confirm the crash already with InDesign CS6 version 8.1.
FWIW: My workaround is good for InDesign CS5.5 version 7.5 and above.
Method insertAnchoredObject() was introduced with 7.5.
Regards,
Uwe Laubender
( ACP )
Copy link to clipboard
Copied
> Method insertAnchoredObject() was introduced with 7.5.
I know! After Dave Saunders harassed Adobe staff for months we finally got it.