pb getchild获取DropDownDW子窗体后进行取值
datawindowchild ldwc
if dw_1.getchild("dwmc", ldwc) = 1 then
long ll_f
ll_f = ldwc.find("dwmc = '" + data + "'", 1, ldwc.rowcount())
if ll_f > 0 then
dw_1.setitem(row,'dwbm',ldwc.getitemstring(ll_f,'dwbm'))//获取DropDownDW中字段值并赋值给其它字段
else //不存在与ldwc中
//看你想怎么操作咯
//ll_f = ldwc.insertrow(0)
//ldwc.setitem(ll_f, 'unitname', unitname)//ldwc_child.setitem(行号, "列名", 值)
end if
end if
DataWindowChild dwc_dz_child
integer retcode_dz
retcode_dz=dw_1.GetChild("daozhanid",dwc_dz_child)
integer retcode_dz
retcode_dz=dw_1.GetChild("daozhanid",dwc_dz_child)
知道行号可以直接根据行号得到显示的内容
dw_data.describe("Evaluate('Lookupdisplay(列名)',行号)")
不知道行号可以通过只查找得到行号在getitemstring
DataWindowChild dwc_dz_child
integer retcode_dz
retcode_dz=dw_1.GetChild("daozhanid",dwc_dz_child)
long ll_f_dz
ll_f_dz = dwc_dz_child.find("cityid = " + ls_daozhan , 1, dwc_dz_child.rowcount())
ls_daozhan=trim(dwc_dz_child.GetItemString(ll_f_dz,"fullname"))