Quantcast
Channel: Adobe Community : Popular Discussions - InDesign Scripting
Viewing all articles
Browse latest Browse all 15932

Table: convert first row to header rows

$
0
0

Hi all and sorry for this question.

I find this script that auto convert to header the first row of a table (we know that using table style - if i set a cell style for header - InDesign do not recognizes the header row that i also set in excel).

 

So i find a script that do it - but have 2 problem: error: 45 (Error string: Object is invalid) Line 4 and works for all table of the document (the best could be if work only with the table selected or of the page). Do you have an idea to solve this?

 

var myTables = app.activeDocument.stories.everyItem().tables;

for (var i = 0; i < myTables.length; i++) {    myTables[i].rows.firstItem().rowType = RowTypes.HEADER_ROW;
}

 

 

(Another problem: what is the best way to set a border table use cell style? I want stroke 1!

The solution to do a stroke to the text frame fitted is a bad way, i think. Can i have a confirm? Yes, i use a table style and cell style - but i see that table style do not override cell style. See also here: http://forums.adobe.com/message/5153224#5153224

 

Many thanks


Viewing all articles
Browse latest Browse all 15932

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>