////定位文本框区域 var loc=new Locator([],OBJECT,DETAIL) //定义颜色 var color = new Color(0x00ff00) var color2 = new Color(0xff0000) var color3 = new Color(0x0000ff) //设置边框颜色。 文本1.setBorderColor(loc, color); //设置前景色即字体颜色。 文本2.setForeground(loc, color2); //设置背景色。 文本3.setBackground(loc, color3); 1、设置文本框边框颜色,字体颜色(前景色)以及背景色:页面脚本-装载时运行写入脚本 
2、获取字体颜色。 (1)页面脚本-装载时运行写入脚本获取。  
获取到的颜色为RGB。 (2)RGB颜色值与十六进制颜色码转换可访问以下地址:https://www.sioe.cn/yingyong/yanse-rgb-16/ 
|