Home > database >  Quadrature quadrature text box
Quadrature quadrature text box

Time:09-29

There are three multiline edit text box sle_sl, sle_dj, sle_je
, respectively, quantity, unit price, amount is how to make the amount of text box is equal to the unit price. Text * number. The text

CodePudding user response:

Do this very fresh, but can realize:
Define three instance variables: dec i_1, i_2, i_3
In the first modified sle_sl write
I_1=dec (this text)
Sle_dj. Setfocus ()
In the second sle_dj modified write
I_2=dec (this text)
I_3=i_1 * i_2
Sle_je. Text=string (i_3, '00. # # #')

CodePudding user response:

When computing is a problem, than the input number first, then input the unit price, here, there are other operations, to calculate,
Another modified only after the input enter triggered, there seems to be a event can be in when the input can be calculated, remember not too clear, you check,
Get to each value of the text box, and then according to your requirement is ok,

CodePudding user response:

refer to the second floor dahaidao response:
what time calculation is a problem, than the input number first, then input the unit price, here, there are other operations, to calculate,
Another modified only after the input enter triggered, there seems to be a event can be in when the input can be calculated, remember not too clear, you check,
Made to the value of the text box, and then calculate can, in accordance with your request
key events, suggested two controls are writing code inside, so, as long as one was changed, can show the result of the changes.

CodePudding user response:

Write a window function, in the two key events of sle calls the function is ok,

CodePudding user response:

The use of an external data sources in a DW can real-time implementation

CodePudding user response:

Define text box control uo_sle user object, the custom event ue_changed, event id for pbm_enchge then write code in each uo_sle:
Long ll_sl, ll_jer
Dec ll_dj
Ll_sl=long (uo_sle1. Text)
Ll_dj=dec (uo_sle2. Text)
Ll_jer=ll_sl * ll_dj
Uo_sle3. Text=string (ll_jer)
Change with input dynamic response keyboard input, the amount

CodePudding user response:

refer to 6th floor yiguanjun response:
define text box control user object uo_sle, ue_changed custom events, event id for pbm_enchge then write code in each uo_sle:
Long ll_sl, ll_jer
Dec ll_dj
Ll_sl=long (uo_sle1. Text)
Ll_dj=dec (uo_sle2. Text)
Ll_jer=ll_sl * ll_dj
Uo_sle3. Text=string (ll_jer)
In response to keyboard input, dynamic change along with the input amount

The use of the learned pbm_enchge today
  • Related