"Expected Unit" when assigning column width on InDesign Server 2015
I'm currently transferring my InDesign scripts to run on InDesign Server 2015, so far everything worked fine, until now.
When I try to assign a width to a column, I receive the following error:
Error String: Invalid value for set property 'width'. Expected Unit, but received "1.058mm".
The code looks like this (listTable is my table object and iEigCol a counter within a for loop, so nothing out of the ordinary):
var spacerColumnWidth = 1.058;
listTable.columns[iEigCol].width = spacerColumnWidth + 'mm';
A few lines earlier I'm using this:
listTable.columns[0].width = '82mm';
Which works just fine.
I already tried these approaches instead:
- Using just the number without the unit
- Using an integer instead of a double
- Concatenating the string before using it to assign the width
- Using a literal string
so far nothing worked here. Strange thing is, that it works on dozens of other columns with any of the mentioned ways to do it.
The exact same script also works fine in InDesign CS5.5.
Any ideas what the problem might be?
Thanks a lot!
