有时我们在编写PB程序时,需要在datawindow数据窗口中添加一个计算域或者直线,这如何进行呢?
//怎样在程序中为datawindow加计算域或line?//以下程序加一计算域sum(dept_id for all)string ls_modrowdw_1.Modify("DataWindow.summary.Height=64")ls_modrow = 'Create compute(band=summary font.charset="0" font.face="MS Sans Serif" font.family="2" font.height="-8" font.pitch="2" font.weight="400" background.mode="1" background.color="536870912" color="0" x="9" y="4" height="52" width="297" format="[general]" expression="sum(dept_id for all)" alignment="1" border="0" crosstab.repeat=no )~r~n'dw_1.modify( ls_modrow )//以下程序加一条线string ls_linedw_1.Modify("DataWindow.detail.Height=332")ls_line = 'Create line(band=detail background.mode="2" background.color="16777215" pen.style="0" pen.width="5" pen.color="0" x1="37" y1="320" x2="1458" y2="316" )~r~n'dw_1.modify( ls_line )dw_1.settransobject(sqlca)dw_1.retrieve()
本文源自:翔宇亭——IT乐园(http://),转载请保留此信息!