w_sys_init_guide.srw 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372
  1. $PBExportHeader$w_sys_init_guide.srw
  2. forward
  3. global type w_sys_init_guide from w_publ_base
  4. end type
  5. type cb_next from uo_imflatbutton within w_sys_init_guide
  6. end type
  7. type st_title from statictext within w_sys_init_guide
  8. end type
  9. type st_info from multilineedit within w_sys_init_guide
  10. end type
  11. type p_1 from picture within w_sys_init_guide
  12. end type
  13. type r_bar from rectangle within w_sys_init_guide
  14. end type
  15. type ln_bar from line within w_sys_init_guide
  16. end type
  17. type ln_bar2 from line within w_sys_init_guide
  18. end type
  19. end forward
  20. global type w_sys_init_guide from w_publ_base
  21. integer width = 2670
  22. integer height = 1868
  23. string title = "初始化设置向导"
  24. boolean minbox = false
  25. windowtype windowtype = response!
  26. long backcolor = 16777215
  27. cb_next cb_next
  28. st_title st_title
  29. st_info st_info
  30. p_1 p_1
  31. r_bar r_bar
  32. ln_bar ln_bar
  33. ln_bar2 ln_bar2
  34. end type
  35. global w_sys_init_guide w_sys_init_guide
  36. type variables
  37. boolean ib_End = false
  38. boolean ib_Begin = true
  39. int CurPage = 0 //当前页数
  40. int PageCnt = 3 //总页数
  41. end variables
  42. forward prototypes
  43. public subroutine wf_setface (integer arg_add)
  44. public subroutine wf_setinfo (string arg_title, string arg_info)
  45. end prototypes
  46. public subroutine wf_setface (integer arg_add);CurPage += arg_add
  47. IF CurPage = 1 THEN
  48. cb_func.Enabled = False
  49. cb_next.Enabled = True
  50. cb_next.Text = "下一步>(&N)"
  51. ELSEIF CurPage >= PageCnt THEN
  52. cb_func.Enabled = True
  53. cb_next.Enabled = True
  54. cb_next.Text = "完成"
  55. ELSE
  56. cb_func.Enabled = True
  57. cb_next.Enabled = True
  58. cb_next.Text = "下一步>(&N)"
  59. END IF
  60. cb_next.TriggerEvent('ue_textchange')
  61. CHOOSE CASE CurPage
  62. CASE 1
  63. IF IsValid(w_sys_init_guide_zt) THEN
  64. w_sys_init_guide_zt.BringToTop = True
  65. ELSE
  66. Open(w_sys_init_guide_zt)
  67. END IF
  68. //w_sys_init_guide_zt.x = 133
  69. w_sys_init_guide_zt.Y = ln_bar.BeginY + 50
  70. w_sys_init_guide_zt.X = (This.Width - w_sys_init_guide_zt.Width ) /2
  71. wf_SetInfo('帐套/版本选择','不同帐套包含不同的系统方案,可以更快捷方便高效处理企业日常业务')
  72. CASE 2
  73. IF IsValid(w_sys_init_guide_zlsz) THEN
  74. w_sys_init_guide_zlsz.BringToTop = True
  75. ELSE
  76. Open(w_sys_init_guide_zlsz)
  77. END IF
  78. w_sys_init_guide_zlsz.X = w_sys_init_guide_zt.X
  79. w_sys_init_guide_zlsz.Y = w_sys_init_guide_zt.Y
  80. w_sys_init_guide_zlsz.Width = w_sys_init_guide_zt.Width
  81. w_sys_init_guide_zlsz.Height = w_sys_init_guide_zt.Height
  82. IF IsValid(w_sys_init_guide_zl) THEN
  83. w_sys_init_guide_zl.Width = w_sys_init_guide_zl.Width - 100
  84. END IF
  85. wf_SetInfo('基础资料设置','初始化预先设置以下基础资料')
  86. CASE 3
  87. IF IsValid(w_sys_init_guide_zl) THEN
  88. w_sys_init_guide_zl.BringToTop = True
  89. ELSE
  90. Open(w_sys_init_guide_zl)
  91. END IF
  92. w_sys_init_guide_zl.X = w_sys_init_guide_zt.X
  93. w_sys_init_guide_zl.Y = w_sys_init_guide_zt.Y
  94. w_sys_init_guide_zl.Width = w_sys_init_guide_zt.Width + 100
  95. w_sys_init_guide_zl.Height = w_sys_init_guide_zt.Height
  96. IF IsValid(w_sys_init_guide_zl) THEN
  97. w_sys_init_guide_zl.Width = w_sys_init_guide_zl.Width - 100
  98. END IF
  99. wf_SetInfo('基础资料设置','系统需要设置以下基础资料就能马上启动帐套,录入日常业务数据')
  100. CASE ELSE //完成
  101. Close(This)
  102. END CHOOSE
  103. end subroutine
  104. public subroutine wf_setinfo (string arg_title, string arg_info);//wf_SetInfo()
  105. st_title.text = arg_title
  106. st_info.text = arg_info
  107. end subroutine
  108. on w_sys_init_guide.create
  109. int iCurrent
  110. call super::create
  111. this.cb_next=create cb_next
  112. this.st_title=create st_title
  113. this.st_info=create st_info
  114. this.p_1=create p_1
  115. this.r_bar=create r_bar
  116. this.ln_bar=create ln_bar
  117. this.ln_bar2=create ln_bar2
  118. iCurrent=UpperBound(this.Control)
  119. this.Control[iCurrent+1]=this.cb_next
  120. this.Control[iCurrent+2]=this.st_title
  121. this.Control[iCurrent+3]=this.st_info
  122. this.Control[iCurrent+4]=this.p_1
  123. this.Control[iCurrent+5]=this.r_bar
  124. this.Control[iCurrent+6]=this.ln_bar
  125. this.Control[iCurrent+7]=this.ln_bar2
  126. end on
  127. on w_sys_init_guide.destroy
  128. call super::destroy
  129. destroy(this.cb_next)
  130. destroy(this.st_title)
  131. destroy(this.st_info)
  132. destroy(this.p_1)
  133. destroy(this.r_bar)
  134. destroy(this.ln_bar)
  135. destroy(this.ln_bar2)
  136. end on
  137. event close;//f_set_sysmessage()
  138. end event
  139. event resize;call super::resize;ln_bar.EndX = THIS.Width
  140. ln_bar2.EndX = THIS.Width
  141. //ln_1.EndX = THIS.Width
  142. //ln_2.EndX = THIS.Width
  143. r_bar.Width = THIS.Width
  144. end event
  145. event open;call super::open;wf_setface(1)
  146. end event
  147. type cb_func from w_publ_base`cb_func within w_sys_init_guide
  148. integer x = 1458
  149. integer y = 1664
  150. integer width = 357
  151. integer height = 96
  152. string text = "<上一步(&B)"
  153. string normalpicname = ""
  154. integer picsize = 0
  155. toolbaralignment pic_align = alignatleft!
  156. boolean border = true
  157. end type
  158. event cb_func::clicked;if w_sys_init_guide_zt.ddlb_sysplan.text="标准材料商业" then
  159. w_sys_init_guide_zt.sle_printbill.text=sys_cur_path + '标准材料商业\ew_printbill.pbl'
  160. elseif w_sys_init_guide_zt.ddlb_sysplan.text="皮布商业" then
  161. w_sys_init_guide_zt.sle_printbill.text=sys_cur_path + '皮布商业\ew_printbill.pbl'
  162. end if
  163. wf_setface(-1)
  164. end event
  165. type cb_exit from w_publ_base`cb_exit within w_sys_init_guide
  166. integer x = 2171
  167. integer y = 1664
  168. integer width = 357
  169. integer taborder = 30
  170. string text = "取消(&C)"
  171. string normalpicname = ""
  172. end type
  173. type cb_next from uo_imflatbutton within w_sys_init_guide
  174. integer x = 1815
  175. integer y = 1664
  176. integer width = 357
  177. integer height = 96
  178. integer taborder = 30
  179. boolean bringtotop = true
  180. string text = "下一步>(&N)"
  181. end type
  182. event clicked;call super::clicked;Int rslt = 1
  183. String arg_msg
  184. IF CurPage = 1 THEN
  185. IF IsValid(w_sys_init_guide_zt) THEN
  186. IF w_sys_init_guide_zt.wf_system_import(arg_msg) <> 1 THEN
  187. rslt = 0
  188. GOTO ext
  189. END IF
  190. IF w_sys_init_guide_zt.wf_copyfile(arg_msg) <> 1 THEN
  191. rslt = 0
  192. GOTO ext
  193. END IF
  194. END IF
  195. END IF
  196. IF CurPage = 2 THEN
  197. END IF
  198. IF CurPage = 3 THEN
  199. String cur_path
  200. cur_path = sys_cur_path + "ewiserp.exe"
  201. IF w_sys_init_guide_zlsz.cbx_1.Checked = True THEN
  202. IF MessageBox('询问','导入基础资料会删除现在所有的基础数据,是否继续?',question!,yesno!) = 2 THEN
  203. GOTO ext
  204. END IF
  205. END IF
  206. w_sys_init_guide_zlsz.wf_insert() //里面有选项删除基础数据
  207. IF MessageBox('询问','初始化重启软件生效,是否退出?',question!,yesno!) = 1 THEN
  208. Run(cur_path)
  209. HALT
  210. END IF
  211. END IF
  212. ext:
  213. IF rslt = 1 THEN
  214. wf_setface(1)
  215. ELSE
  216. MessageBox('提示', arg_msg)
  217. END IF
  218. end event
  219. type st_title from statictext within w_sys_init_guide
  220. integer x = 37
  221. integer y = 16
  222. integer width = 1129
  223. integer height = 56
  224. boolean bringtotop = true
  225. integer textsize = -10
  226. integer weight = 700
  227. fontcharset fontcharset = gb2312charset!
  228. fontpitch fontpitch = variable!
  229. string facename = "宋体"
  230. long textcolor = 33554432
  231. long backcolor = 134217739
  232. string text = "标题内容"
  233. boolean focusrectangle = false
  234. end type
  235. event constructor;this.backcolor = 14215660
  236. end event
  237. type st_info from multilineedit within w_sys_init_guide
  238. integer x = 96
  239. integer y = 88
  240. integer width = 2290
  241. integer height = 136
  242. integer taborder = 10
  243. boolean bringtotop = true
  244. integer textsize = -10
  245. integer weight = 400
  246. fontcharset fontcharset = gb2312charset!
  247. fontpitch fontpitch = variable!
  248. string facename = "宋体"
  249. long textcolor = 33554432
  250. string text = "简单介绍"
  251. boolean border = false
  252. boolean displayonly = true
  253. end type
  254. event constructor;this.backcolor = 14215660
  255. end event
  256. type p_1 from picture within w_sys_init_guide
  257. integer x = 2414
  258. integer y = 16
  259. integer width = 229
  260. integer height = 196
  261. boolean bringtotop = true
  262. boolean originalsize = true
  263. string picturename = "graphics\cshxd.jpg"
  264. boolean focusrectangle = false
  265. end type
  266. type r_bar from rectangle within w_sys_init_guide
  267. long linecolor = 16777215
  268. integer linethickness = 4
  269. long fillcolor = 1073741824
  270. integer width = 1312
  271. integer height = 156
  272. end type
  273. event constructor;this.fillcolor = 14215660
  274. this.linecolor = 14215660
  275. this.x = -1
  276. this.y = -1
  277. this.height = ln_bar.beginy - 5
  278. end event
  279. type ln_bar from line within w_sys_init_guide
  280. long linecolor = 268435456
  281. integer linethickness = 4
  282. integer beginy = 224
  283. integer endx = 3200
  284. integer endy = 224
  285. end type
  286. type ln_bar2 from line within w_sys_init_guide
  287. long linecolor = 16777215
  288. integer linethickness = 4
  289. integer beginx = 9
  290. integer beginy = 228
  291. integer endx = 3273
  292. integer endy = 228
  293. end type