Running version V13.13.9, testing source code.
var $ = this;
var xdlg, xcrt, xcmd, xutil;
function OnClick(clickData) {
// --------------------------------------------------------
// DOpus.ClearOutput();
// --------------------------------------------------------
$.xutil = DOpus.FSUtil;
$.xcrt = DOpus.Create;
$.xcmd = xcrt.Command; // clickData.func.command;
$.xdlg = DOpus.Dlg;
$.xdlg.window = DOpus.Listers(0);
$.xdlg.title = "DService";
$.xdlg.template = "P0";
$.xdlg.detach = true;
$.xdlg.opacity = 200;
$.xdlg.Show();
$.loadListView();
while(true){
var Msg = $.xdlg.GetMsg();
if (!Msg.result) break;
var focus = Msg.focus;
var event = Msg.event;
var mctrl = Msg.control;
var value = String(Msg.value);
var index = String(Msg.index);
var data = String(Msg.data);
if(focus){
$.xlog("The " + mctrl + " Focus...");
}
if(event === "drop"){
$.xlog("Drop Event...");
}
}
}
function loadListView(){
var listView = $.xdlg.Control("listview1");
var dataList = $.getDataList();
try{
for(var i = 0; i < dataList.length; i++){
var rdata = dataList[i];
var rid = listView.AddItem(rdata[0]);
var items = listView.GetItemAt(rid);
for(var d = 1; d < rdata.length; d++){
//$.xlog(rdata[d]);
items.subitems(d-1) = rdata[d];
}
var cell3 = items.subitems(2);
if(String(cell3).search("/08/") > 0){
cell3.fg("#3099ff");
cell3.styles("u", "b");
//cell3.styles("b", "i", "u");
//cell3.styles("u");
}
var cell5 = items.subitems(4);
//$.xlog(cell5);
if(Number(cell5) > 2000){
cell5.fg("#FFFFFF");
cell5.bg("#FF0000");
cell5.styles("b");
}
}
listView.columns.AutoSize();
}catch(err){
$.xlog("error message: " + err.message);
}
}
function getDataList(){
var datas = [
[1001, "PRO-SHA", "UW-F20-10", "2005/07/01", "45.2", "1500", "N", "200", "v1.3.13"],
[2001, "PRO-SHA", "UW-F20-11", "2006/06/12", "40.23", "2343", "Y", "343", "v2.5.1"],
[3001, "PRO-SHA", "UW-F20-12", "2006/08/20", "53.39", "1120", "Y", "90", "v1.4.22"],
[4001, "PRO-SHB", "UW-K45-S4", "2007/05/23", "58.9", "300", "N", "10", "v2.8.0"],
[5001, "PRO-SHB", "UW-K09-G5", "2008/03/13", "60.33", "532", "Y", "20", "v4.6.1"],
[6001, "PRO-SHB", "UW-K21-R3", "2008/09/14", "64.78", "1430", "N", "180", "v1.1.19"],
[7001, "PRO-SHC", "UW-J33-56", "2010/04/28", "67.45", "2800", "Y", "520", "v7.12.04"],
[8001, "PRO-SHC", "UW-J52-24", "2011/08/19", "70.49", "3740", "Y", "940", "v9.15.08"],
[9001, "PRO-SHC", "UW-J63-39", "2013/01/04", "70.14", "5999", "Y", "1260", "v11.9.03"],
[10001, "PRO-SHC", "UW-J89-75", "2013/11/16", "67.78", "7810", "Y", "2790", "v11.12.03"]
];
return datas;
}
// print log
function xlog(str){
DOpus.Output(String(str));
}
<resources>
<resource name="P0" type="dialog">
<dialog height="183" lang="chs" maximize="yes" minimize="yes" opacity="230" resize="yes" title="DService" width="374">
<control height="175" name="tab1" type="tab" width="366" x="5" y="4">
<tabs>
<tab dialog="P1" />
<tab dialog="P2" />
<tab dialog="P3" />
</tabs>
</control>
</dialog>
</resource>
<resource name="P1" type="dialog">
<dialog height="158" lang="chs" title="DataList" width="360">
<control halign="left" height="12" name="xid" tip=" " type="edit" width="64" x="34" y="7" />
<control halign="left" height="8" name="static1" title="Id:" type="static" valign="top" width="12" x="18" y="10" />
<control fullrow="yes" height="132" name="listview1" type="listview" viewmode="details" width="360" x="0" y="26">
<columns>
<item text="Id" />
<item text="Project" />
<item text="Name" />
<item text="Date" />
<item text="Price" />
<item text="Sales" />
<item text="Status" />
<item text="Likes" />
<item text="Version" />
<item text="Download" />
<item text="Remark" />
</columns>
</control>
<control halign="left" height="8" name="static2" title="Name:" type="static" valign="top" width="27" x="120" y="9" />
<control halign="left" height="12" name="xname" tip=" " type="edit" width="73" x="148" y="7" />
</dialog>
</resource>
<resource name="P2" type="dialog">
<dialog height="159" lang="chs" title="BaseList" width="360">
<control halign="left" height="12" name="pname" tip=" " type="edit" width="64" x="47" y="6" />
<control height="134" name="listview2" type="listview" viewmode="details" width="360" x="0" y="25">
<columns>
<item text="Id" />
<item text="Project" />
<item text="Name" />
<item text="Price" />
<item text="Status" />
<item text="Version" />
<item text="Remark" />
</columns>
</control>
<control halign="left" height="8" name="sname" title="Name" type="static" valign="top" width="20" x="14" y="8" />
</dialog>
</resource>
<resource name="P3" type="dialog">
<dialog height="158" lang="chs" title="AddInfo" width="360">
<control height="102" name="tab2" type="tab" width="360" x="0" y="56">
<tabs>
<tab dialog="P4" />
<tab dialog="P5" />
<tab dialog="P6" />
</tabs>
</control>
<control halign="left" height="8" name="sid" title="Id:" type="static" valign="top" width="12" x="18" y="10" />
<control halign="left" height="12" name="fid" tip=" " type="edit" width="64" x="35" y="7" />
<control halign="left" height="8" name="sname" title="Name:" type="static" valign="top" width="29" x="119" y="10" />
<control halign="left" height="12" name="fname" tip=" " type="edit" width="64" x="151" y="8" />
<control halign="left" height="8" name="sversion" title="Version:" type="static" valign="top" width="29" x="10" y="34" />
<control halign="left" height="12" name="fversion" tip=" " type="edit" width="64" x="44" y="32" />
<control halign="left" height="8" name="sstatus" title="Status:" type="static" valign="top" width="26" x="129" y="34" />
<control height="40" name="fstatus" type="combo" width="64" x="158" y="32">
<contents>
<item text="Yes" />
<item text="No" />
</contents>
</control>
<control height="14" name="addbtn" title="Add" type="button" width="50" x="259" y="31" />
<control halign="left" height="8" name="sprice" title="Price:" type="static" valign="top" width="21" x="234" y="10" />
<control halign="left" height="12" name="fprice" tip=" " type="edit" width="64" x="260" y="8" />
</dialog>
</resource>
<resource name="P4" type="dialog">
<dialog height="87" lang="chs" width="356">
<control height="87" name="group4" title="Group4" type="group" width="356" x="0" y="0" />
<control height="78" name="listview4" type="listview" viewmode="details" width="356" x="0" y="9">
<columns>
<item text="Id" />
<item text="Project" />
<item text="Name" />
<item text="Price" />
<item text="Status" />
<item text="Date" />
<item text="Remark" />
</columns>
</control>
</dialog>
</resource>
<resource name="P5" type="dialog">
<dialog height="87" lang="chs" width="356">
<control height="87" name="group5" title="Group5" type="group" width="356" x="0" y="0" />
<control height="15" name="datetime1" title="日期/时间选取器" type="datetime" width="67" x="156" y="36" />
<control halign="left" height="8" name="date5" title="Date:" type="static" valign="top" width="20" x="132" y="40" />
</dialog>
</resource>
<resource name="P6" type="dialog">
<dialog height="87" lang="chs" width="356">
<control height="87" name="group6" title="Group6" type="group" width="356" x="0" y="0" />
<control height="14" name="palette1" title="调色板" type="palette" width="50" x="172" y="35" />
<control halign="left" height="8" name="color6" title="Color:" type="static" valign="top" width="26" x="146" y="39" />
</dialog>
</resource>
</resources>