如何仅为标题列更改内部边框的颜色?

问题描述 投票:0回答:1

我想将一个表输出到RTF中,表中没有行,但在标题单元格中有内部边框。此外,标题列是丰富多彩的。我知道如何更改所有单元格的边框颜色,但我无法弄清楚如何只更改标题颜色。我需要用proc模板来做。现在我得到这张桌子:

enter image description here

但我需要像这样:

enter image description here

代码是:

proc template;
define style styles.new;
parent = Styles.Printer;

replace color_list /
'link' = blue 
'bgH' = cxFF8200 
'bgT' = white 
'bgD' = white 
'fg' = black
'bg' = white; 

replace Table from Output /
frame = hsides 
rules = groups 
cellpadding = 2pt 
cellspacing = 0.25pt 
borderwidth = 0.75pt 
background = color_list('bgt') ;

end;
run;
ods listing style=new;

有人能告诉我,我怎么能改变代码才能得到正确的输出?谢谢!

templates sas rtf ods
1个回答
0
投票

您看到的白色标题分隔“行”实际上并未绘制。

更改为cellspacing=1in,您将观察到'线'实际上是间距的伪影并且对应于整体背景。我认为有一种简单的方法可以使标题单元格边框与数据单元格边框不同。

© www.soinside.com 2019 - 2024. All rights reserved.