w_inputbox_long.srw 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. $PBExportHeader$w_inputbox_long.srw
  2. $PBExportComments$long数据类型输入框
  3. forward
  4. global type w_inputbox_long from w_publ_base
  5. end type
  6. type st_1 from statictext within w_inputbox_long
  7. end type
  8. type em_1 from editmask within w_inputbox_long
  9. end type
  10. end forward
  11. global type w_inputbox_long from w_publ_base
  12. integer height = 468
  13. string title = "输入整数"
  14. boolean minbox = false
  15. windowtype windowtype = response!
  16. boolean center = true
  17. st_1 st_1
  18. em_1 em_1
  19. end type
  20. global w_inputbox_long w_inputbox_long
  21. type variables
  22. s_inputbox ins_parm
  23. end variables
  24. on w_inputbox_long.create
  25. int iCurrent
  26. call super::create
  27. this.st_1=create st_1
  28. this.em_1=create em_1
  29. iCurrent=UpperBound(this.Control)
  30. this.Control[iCurrent+1]=this.st_1
  31. this.Control[iCurrent+2]=this.em_1
  32. end on
  33. on w_inputbox_long.destroy
  34. call super::destroy
  35. destroy(this.st_1)
  36. destroy(this.em_1)
  37. end on
  38. event open;call super::open;ins_parm = Message.PowerObjectParm
  39. if (IsNull(ins_parm)) then
  40. Close(this)
  41. return
  42. end if
  43. if (not IsValid(ins_parm)) then
  44. Close(this)
  45. return
  46. end if
  47. this.Title = ins_parm.title
  48. st_1.Text = ins_parm.msg
  49. em_1.Text = string(ins_parm.long_a)
  50. em_1.SetFocus()
  51. em_1.SelectText(1, len(em_1.Text))
  52. ins_parm.ifret = false
  53. end event
  54. event close;call super::close;CloseWithReturn(this, ins_parm)
  55. end event
  56. type cb_func from w_publ_base`cb_func within w_inputbox_long
  57. integer x = 699
  58. integer y = 276
  59. integer taborder = 10
  60. string text = "确认"
  61. boolean default = true
  62. end type
  63. event cb_func::clicked;ins_parm.long_a = long(em_1.Text)
  64. ins_parm.ifret = true
  65. Close(parent)
  66. end event
  67. type cb_exit from w_publ_base`cb_exit within w_inputbox_long
  68. integer x = 1015
  69. integer y = 276
  70. integer taborder = 20
  71. end type
  72. type st_1 from statictext within w_inputbox_long
  73. integer y = 4
  74. integer width = 2007
  75. integer height = 148
  76. boolean bringtotop = true
  77. integer textsize = -9
  78. integer weight = 400
  79. fontcharset fontcharset = gb2312charset!
  80. fontpitch fontpitch = variable!
  81. string facename = "宋体"
  82. long textcolor = 33554432
  83. long backcolor = 134217739
  84. string text = "ins_parm.msg"
  85. boolean focusrectangle = false
  86. end type
  87. type em_1 from editmask within w_inputbox_long
  88. integer x = 800
  89. integer y = 172
  90. integer width = 402
  91. integer height = 84
  92. integer taborder = 30
  93. boolean bringtotop = true
  94. integer textsize = -9
  95. integer weight = 400
  96. fontcharset fontcharset = gb2312charset!
  97. fontpitch fontpitch = variable!
  98. string facename = "宋体"
  99. long textcolor = 33554432
  100. string text = "0"
  101. alignment alignment = Center!
  102. borderstyle borderstyle = stylelowered!
  103. string mask = "#####"
  104. boolean spin = true
  105. end type