$PBExportHeader$w_publ_preview_mdfcrptxwidth.srw forward global type w_publ_preview_mdfcrptxwidth from w_publ_base end type type cb_reset from uo_imflatbutton within w_publ_preview_mdfcrptxwidth end type type cb_2 from uo_imflatbutton within w_publ_preview_mdfcrptxwidth end type type cb_ok from uo_imflatbutton within w_publ_preview_mdfcrptxwidth end type type cb_yy from uo_imflatbutton within w_publ_preview_mdfcrptxwidth end type type dw_1 from u_dw_rbtnfilter within w_publ_preview_mdfcrptxwidth end type end forward global type w_publ_preview_mdfcrptxwidth from w_publ_base integer x = 46 integer y = 272 integer width = 3611 integer height = 1660 string title = "明细网格列序列宽调整" boolean minbox = false windowtype windowtype = response! long backcolor = 80269524 cb_reset cb_reset cb_2 cb_2 cb_ok cb_ok cb_yy cb_yy dw_1 dw_1 end type global w_publ_preview_mdfcrptxwidth w_publ_preview_mdfcrptxwidth type variables s_childreportxwidth s_xwidth s_mdfxwidth_tran s_mdfxw_tran datastore ds_dt end variables forward prototypes public function integer wf_ok () public subroutine wf_retrieve () end prototypes public function integer wf_ok ();int ls_i,ls_clmno ls_clmno=integer(dw_1.Describe('DataWindow.Column.Count')) for ls_i=1 to ls_clmno s_xwidth.width[ls_i]=integer( dw_1.Describe('#'+string(ls_i)+'.width')) s_xwidth.x[ls_i]=integer( dw_1.Describe('#'+string(ls_i)+'.x')) next s_xwidth.p=ls_clmno if dw_1.Describe('cmpl1.name')='cmpl1' then s_xwidth.cmplwidth[1]=integer( dw_1.Describe('cmpl1.width')) s_xwidth.cmplx[1]=integer( dw_1.Describe('cmpl1.x')) s_xwidth.cmplp=1 end if if dw_1.Describe('cmpl2.name')='cmpl2' then s_xwidth.cmplwidth[2]=integer( dw_1.Describe('cmpl2.width')) s_xwidth.cmplx[2]=integer( dw_1.Describe('cmpl2.x')) s_xwidth.cmplp=s_xwidth.cmplp+2 end if if dw_1.Describe('cmpl3.name')='cmpl3' then s_xwidth.cmplwidth[3]=integer( dw_1.Describe('cmpl3.width')) s_xwidth.cmplx[3]=integer( dw_1.Describe('cmpl3.x')) s_xwidth.cmplp=s_xwidth.cmplp+4 end if return 0 end function public subroutine wf_retrieve ();dw_1.dataobject=s_mdfxw_tran.dataobject dw_1.settransobject(sqlca) choose case s_mdfxw_tran.retrievetype case 1 dw_1.retrieve(s_mdfxw_tran.retrievestr) case 2 dw_1.retrieve(s_mdfxw_tran.retrieveid) case 5 dw_1.retrieve(s_mdfxw_tran.retrieveid,s_mdfxw_tran.secondretrieveid) case 14 dw_1.retrieve(s_mdfxw_tran.retrieveid,s_mdfxw_tran.retrievestr) end choose //string new_sqlstr //long pos_dot1,pos_dot2 //new_sqlstr=dw_1.Describe("DataWindow.Table.Select") //pos_dot1=pos(new_sqlstr,':',1) //pos_dot2=pos(new_sqlstr,':',pos_dot1 + 1) // //if pos_dot2=0 then // dw_1.retrieve(s_mdfxw_tran.retrieveid) //else // dw_1.retrieve(s_mdfxw_tran.retrieveid,s_mdfxw_tran.secondretrieveid) //end if dw_1.object.DataWindow.Print.Preview = 'yes' end subroutine on w_publ_preview_mdfcrptxwidth.create int iCurrent call super::create this.cb_reset=create cb_reset this.cb_2=create cb_2 this.cb_ok=create cb_ok this.cb_yy=create cb_yy this.dw_1=create dw_1 iCurrent=UpperBound(this.Control) this.Control[iCurrent+1]=this.cb_reset this.Control[iCurrent+2]=this.cb_2 this.Control[iCurrent+3]=this.cb_ok this.Control[iCurrent+4]=this.cb_yy this.Control[iCurrent+5]=this.dw_1 end on on w_publ_preview_mdfcrptxwidth.destroy call super::destroy destroy(this.cb_reset) destroy(this.cb_2) destroy(this.cb_ok) destroy(this.cb_yy) destroy(this.dw_1) end on event open;call super::open;ds_dt = CREATE datastore s_xwidth.p = 0 s_mdfxw_tran = Message.PowerObjectParm IF s_mdfxw_tran.retrieveid = 0 and s_mdfxw_tran.retrievestr = '' OR Trim(s_mdfxw_tran.DataObject) = '' THEN Close(THIS) RETURN END IF wf_retrieve() //ds_dt.dataobject=s_mdfxw_tran.dataobject //ds_dt.settransobject(sqlca) //ds_dt.retrieve(s_mdfxw_tran.retrieveid) // //dw_1.dataobject=s_mdfxw_tran.dataobject //dw_1.settransobject(sqlca) //dw_1.retrieve(s_mdfxw_tran.retrieveid) // ////ds_dt.sharedata(dw_1) // //dw_1.object.DataWindow.Print.Preview = 'yes' end event event close;closewithreturn(this, s_xwidth) end event type cb_func from w_publ_base`cb_func within w_publ_preview_mdfcrptxwidth boolean visible = false integer x = 2048 integer y = 1408 integer width = 338 boolean enabled = false end type type cb_exit from w_publ_base`cb_exit within w_publ_preview_mdfcrptxwidth integer x = 2825 integer y = 1408 integer width = 338 string text = "取消" end type type cb_reset from uo_imflatbutton within w_publ_preview_mdfcrptxwidth integer x = 288 integer y = 1408 integer width = 270 integer height = 96 integer taborder = 50 string text = "重置" end type event clicked;call super::clicked;wf_retrieve() //dw_1.dataobject=s_mdfxw_tran.dataobject //dw_1.settransobject(sqlca) //dw_1.retrieve(s_mdfxw_tran.retrieveid) ////ds_dt.sharedata(dw_1) //dw_1.object.DataWindow.Print.Preview = 'yes' end event type cb_2 from uo_imflatbutton within w_publ_preview_mdfcrptxwidth integer x = 5 integer y = 1408 integer width = 270 integer height = 96 integer taborder = 60 string text = "数据发送" end type event clicked;call super::clicked;OPENWITHPARM(w_sentdataout,dw_1) end event type cb_ok from uo_imflatbutton within w_publ_preview_mdfcrptxwidth integer x = 2464 integer y = 1408 integer width = 338 integer height = 96 integer taborder = 50 boolean default = true end type event clicked;call super::clicked;wf_ok() close(parent) end event type cb_yy from uo_imflatbutton within w_publ_preview_mdfcrptxwidth integer x = 3186 integer y = 1408 integer width = 338 integer height = 96 integer taborder = 30 string text = "应用" end type event clicked;call super::clicked; if not isvalid(w_publ_preview) then return wf_ok() w_publ_preview.wf_mdfmxreport(s_xwidth) end event type dw_1 from u_dw_rbtnfilter within w_publ_preview_mdfcrptxwidth integer width = 3557 integer height = 1388 integer taborder = 50 boolean bringtotop = true boolean hscrollbar = true boolean vscrollbar = true end type event constructor;call super::constructor;titleclick_sort_use=true //单击标题排序功能开关 end event