$PBExportHeader$w_set_scdb.srw forward global type w_set_scdb from w_publ_base end type type cbx_his from checkbox within w_set_scdb end type type gb_1 from groupbox within w_set_scdb end type type mle_1 from multilineedit within w_set_scdb end type type cbx_switch from checkbox within w_set_scdb end type end forward global type w_set_scdb from w_publ_base integer width = 1783 integer height = 580 string title = "数据库设定" boolean minbox = false windowtype windowtype = response! long backcolor = 80269524 cbx_his cbx_his gb_1 gb_1 mle_1 mle_1 cbx_switch cbx_switch end type global w_set_scdb w_set_scdb type variables uo_getdbinfo uo_setdbinfo end variables on w_set_scdb.create int iCurrent call super::create this.cbx_his=create cbx_his this.gb_1=create gb_1 this.mle_1=create mle_1 this.cbx_switch=create cbx_switch iCurrent=UpperBound(this.Control) this.Control[iCurrent+1]=this.cbx_his this.Control[iCurrent+2]=this.gb_1 this.Control[iCurrent+3]=this.mle_1 this.Control[iCurrent+4]=this.cbx_switch end on on w_set_scdb.destroy call super::destroy destroy(this.cbx_his) destroy(this.gb_1) destroy(this.mle_1) destroy(this.cbx_switch) end on event open;call super::open;uo_setdbinfo=create uo_getdbinfo end event event close;call super::close;halt end event type cb_func from w_publ_base`cb_func within w_set_scdb integer x = 1010 integer y = 344 integer width = 311 integer height = 100 string text = "确定" toolbaralignment pic_align = alignatleft! end type event cb_func::clicked;String arg_msg Int li_hisflag,li_switchflag IF cbx_his.Checked THEN li_hisflag = 1 ELSE li_hisflag = 0 END IF IF cbx_switch.Checked THEN li_switchflag = 1 ELSE li_switchflag = 0 END IF IF uo_setdbinfo.set_dbinfo(sqlca,li_hisflag,li_switchflag,arg_msg) = 0 THEN MessageBox("提示",arg_msg, Information!, OK! ) RETURN END IF MessageBox("提示",'初始化数据库成功,请重新登录', Information!, OK! ) HALT end event type cb_exit from w_publ_base`cb_exit within w_set_scdb integer x = 1390 integer y = 344 integer height = 100 integer taborder = 30 string text = "取消" end type event cb_exit::clicked;halt end event type cbx_his from checkbox within w_set_scdb integer x = 73 integer y = 316 integer width = 521 integer height = 76 boolean bringtotop = true integer textsize = -9 integer weight = 400 fontcharset fontcharset = gb2312charset! fontpitch fontpitch = variable! string facename = "宋体" long textcolor = 33554432 long backcolor = 67108864 string text = "设定为历史数据库" end type type gb_1 from groupbox within w_set_scdb integer x = 41 integer y = 20 integer width = 1701 integer height = 244 integer taborder = 20 integer textsize = -9 integer weight = 400 fontcharset fontcharset = gb2312charset! fontpitch fontpitch = variable! string facename = "宋体" long textcolor = 16711935 long backcolor = 67108864 string text = "说明" end type type mle_1 from multilineedit within w_set_scdb integer x = 64 integer y = 84 integer width = 1650 integer height = 140 integer taborder = 20 boolean bringtotop = true integer textsize = -9 integer weight = 400 fontcharset fontcharset = gb2312charset! fontpitch fontpitch = variable! string facename = "宋体" long textcolor = 32768 string text = " 数据库可设定为历史查询数据库或日常正式使用数据库,每月已完成的数据将转入历史查询数据库作查询用途。" boolean displayonly = true borderstyle borderstyle = stylelowered! end type type cbx_switch from checkbox within w_set_scdb boolean visible = false integer x = 73 integer y = 408 integer width = 608 integer height = 76 boolean bringtotop = true integer textsize = -9 integer weight = 400 fontcharset fontcharset = gb2312charset! fontpitch fontpitch = variable! string facename = "宋体" long textcolor = 33554432 long backcolor = 67108864 boolean enabled = false string text = "设定为切换数据库" end type