Using v17r4.

I'm finding it "challenging" to add styling to tables in a WP document.

*Problem no. 1: Attributes are applied to the wrong row*
Here is some simple sample code:

$rows:=*WP Get elements*(wptable;wk type table row)

$n:=$rows.length // $n = 3

$row:=$rows[1]

*WP SET ATTRIBUTES*($row;wk font bold;*True*)

*WP SET ATTRIBUTES*($row;wk font size;"16pt")

These attributes are applied, but to Row 2 instead of Row 1!

*Problem no. 2: Cannot apply a stylesheet*
Using the same code as above, with this added:
tStyleSheetName:="header_row"

*WP SET ATTRIBUTES*($row;wk style sheet;tStyleSheetName)

I get the error:
"unknown stylesheet name: header_row"

But header_row is definitely defined within the document. Stylesheets are
applied in the same manner elsewhere in the document, and they work fine -
just not when applied to tables.

Am I doing something wrong or are these two bugs?

Pat

-- 
*************************************************
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*************************************************
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to