$PBExportHeader$w_publ_inputexpr.srw
forward
global type w_publ_inputexpr from w_publ_base
end type
type cb_add from uo_imflatbutton within w_publ_inputexpr
end type
type cb_repl from uo_imflatbutton within w_publ_inputexpr
end type
type cbx_dist from checkbox within w_publ_inputexpr
end type
type cb_setposition from uo_imflatbutton within w_publ_inputexpr
end type
type ddlb_op from dropdownlistbox within w_publ_inputexpr
end type
type sle_nr from multilineedit within w_publ_inputexpr
end type
type st_1 from statictext within w_publ_inputexpr
end type
end forward

global type w_publ_inputexpr from w_publ_base
integer x = 407
integer y = 224
integer width = 1943
integer height = 644
string title = "请填入补充内容"
boolean controlmenu = false
boolean minbox = false
windowtype windowtype = response!
cb_add cb_add
cb_repl cb_repl
cbx_dist cbx_dist
cb_setposition cb_setposition
ddlb_op ddlb_op
sle_nr sle_nr
st_1 st_1
end type
global w_publ_inputexpr w_publ_inputexpr

type variables

string cur_filter_expr
 //当前FILTER表达式

string cur_filter_expr_INCHA 
//当前FILTER表达式中文表示
s_esq_tran ls_esq_tran
//返回结构

INT SHORTHEIGHT=380,LONGHEIGHT=1000
end variables

on w_publ_inputexpr.create
int iCurrent
call super::create
this.cb_add=create cb_add
this.cb_repl=create cb_repl
this.cbx_dist=create cbx_dist
this.cb_setposition=create cb_setposition
this.ddlb_op=create ddlb_op
this.sle_nr=create sle_nr
this.st_1=create st_1
iCurrent=UpperBound(this.Control)
this.Control[iCurrent+1]=this.cb_add
this.Control[iCurrent+2]=this.cb_repl
this.Control[iCurrent+3]=this.cbx_dist
this.Control[iCurrent+4]=this.cb_setposition
this.Control[iCurrent+5]=this.ddlb_op
this.Control[iCurrent+6]=this.sle_nr
this.Control[iCurrent+7]=this.st_1
end on

on w_publ_inputexpr.destroy
call super::destroy
destroy(this.cb_add)
destroy(this.cb_repl)
destroy(this.cbx_dist)
destroy(this.cb_setposition)
destroy(this.ddlb_op)
destroy(this.sle_nr)
destroy(this.st_1)
end on

event open;call super::open;ls_esq_tran=Message.PowerObjectParm	
this.title='筛选项目: '+ls_esq_tran.title +' 包含'
sle_nr.text=ls_esq_tran.cur_data
cur_filter_expr=ls_esq_tran.cur_filter_expr
cur_filter_expr_INCHA=ls_esq_tran.cur_filter_expr_INCHA
//THIS.HEIGHT=512

environment   exerun_env 
GetEnvironment(exerun_env ) 

this.x=ls_esq_tran.x - 200
this.y=ls_esq_tran.y - 130
if this.x<0 then this.x=0
if this.y<0 then this.y=0
if this.x > PixelsToUnits(exerun_env.screenwidth, XPixelsToUnits!) - this.Width then this.x = PixelsToUnits(exerun_env.screenwidth, XPixelsToUnits!) - this.Width
if this.y > PixelsToUnits(exerun_env.screenheight, yPixelsToUnits!) - this.HeighT then this.y = PixelsToUnits(exerun_env.screenheight, yPixelsToUnits!) - this.HeighT

ls_esq_tran.return_flag=0

if trim(sle_nr.text)<>''  then 
//	cb_add.enabled=true
	sle_nr.SelectText(1,len(sle_nr.text))
end if

end event

event close;CloseWithReturn(THIS,ls_esq_tran) 
end event

event rbuttondown;call super::rbuttondown;cb_exit.TriggerEvent(clicked!)
end event

type cb_func from w_publ_base`cb_func within w_publ_inputexpr
boolean visible = false
integer x = 1609
integer y = 452
integer taborder = 30
boolean enabled = false
end type

type cb_exit from w_publ_base`cb_exit within w_publ_inputexpr
integer x = 1527
integer y = 452
integer width = 325
integer taborder = 60
string text = "取消"
end type

event cb_exit::clicked;ls_esq_tran.cur_data = Trim(sle_nr.Text)
ls_esq_tran.DIST_BOOLEAN = cbx_dist.Checked
ls_esq_tran.comp_op = ddlb_op.Text
ls_esq_tran.return_flag = 0
Close(PARENT)

end event

type cb_add from uo_imflatbutton within w_publ_inputexpr
integer x = 777
integer y = 452
integer width = 325
integer height = 96
integer taborder = 80
string text = "增加条件"
end type

event clicked;call super::clicked;ls_esq_tran.cur_data = Trim(sle_nr.Text)
ls_esq_tran.return_flag = 1
ls_esq_tran.DIST_BOOLEAN = cbx_dist.Checked
ls_esq_tran.comp_op = ddlb_op.Text
Close(PARENT)

end event

type cb_repl from uo_imflatbutton within w_publ_inputexpr
integer x = 402
integer y = 452
integer width = 325
integer height = 96
integer taborder = 20
string text = "重新查询"
boolean default = true
end type

event clicked;call super::clicked;IF Pos(Trim(sle_nr.Text),"'") > 0 THEN
	MessageBox('提示',"录入内容不能包含符号'")
	RETURN
END IF
ls_esq_tran.cur_data = Trim(sle_nr.Text)
ls_esq_tran.return_flag = 2
ls_esq_tran.DIST_BOOLEAN = cbx_dist.Checked
ls_esq_tran.comp_op = ddlb_op.Text
Close(PARENT)

end event

type cbx_dist from checkbox within w_publ_inputexpr
integer x = 14
integer y = 192
integer width = 379
integer height = 60
integer taborder = 50
boolean bringtotop = true
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
long backcolor = 134217739
string text = "区分大小写"
end type

type cb_setposition from uo_imflatbutton within w_publ_inputexpr
integer x = 1152
integer y = 452
integer width = 325
integer height = 96
integer taborder = 70
boolean bringtotop = true
string text = "定位"
boolean default = true
end type

event clicked;call super::clicked;ls_esq_tran.cur_data = Trim(sle_nr.Text)
ls_esq_tran.return_flag = 4
ls_esq_tran.DIST_BOOLEAN = cbx_dist.Checked
ls_esq_tran.comp_op = ddlb_op.Text
Close(PARENT)

end event

type ddlb_op from dropdownlistbox within w_publ_inputexpr
integer x = 14
integer y = 84
integer width = 338
integer height = 552
integer taborder = 40
boolean bringtotop = true
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
string text = "包含"
boolean sorted = false
string item[] = {"包含","不包含","等于","不等于","大于","小于","大于等于","小于等于"}
borderstyle borderstyle = stylelowered!
end type

type sle_nr from multilineedit within w_publ_inputexpr
integer x = 402
integer y = 88
integer width = 1504
integer height = 344
integer taborder = 10
boolean bringtotop = true
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 33554432
boolean vscrollbar = true
borderstyle borderstyle = stylelowered!
end type

type st_1 from statictext within w_publ_inputexpr
integer x = 14
integer y = 20
integer width = 1275
integer height = 48
boolean bringtotop = true
integer textsize = -9
integer weight = 400
fontcharset fontcharset = gb2312charset!
fontpitch fontpitch = variable!
string facename = "宋体"
long textcolor = 255
long backcolor = 134217739
string text = "提示: 按住Ctrl+回车可实现换行,同时查询多个资料"
boolean focusrectangle = false
end type

