Perform calculations when a button is Clicked
Posted: Thu Sep 20, 2012 4:04 pm
I intend to do the following, Pls help with the calculation Code:
1. retrieve data from MySQL Table
2. Perform Calculation with the data to get result (to 2 decimal Place)
3.the result is generated when a Button in the Form is Clicked.
The Details are as follows:
Items| Qty | Price | Qty2 | price2 | Amnt | Amnt2 | Pay
Shoe| 2 | 500 | 5 | 700 | x | x | x
The Calculation to perform is:
Amnt = price1 * qty
Amnt2 = price2 * qty2
total = qty1 + qty2
pay = amnt1+amnt2/total
Pay should be in 2 decimal Place, and would be genera when a Button is clicked.
Pls Help with the Calculation and Clicking Code.
Thanks
1. retrieve data from MySQL Table
2. Perform Calculation with the data to get result (to 2 decimal Place)
3.the result is generated when a Button in the Form is Clicked.
The Details are as follows:
Items| Qty | Price | Qty2 | price2 | Amnt | Amnt2 | Pay
Shoe| 2 | 500 | 5 | 700 | x | x | x
The Calculation to perform is:
Amnt = price1 * qty
Amnt2 = price2 * qty2
total = qty1 + qty2
pay = amnt1+amnt2/total
Pay should be in 2 decimal Place, and would be genera when a Button is clicked.
Pls Help with the Calculation and Clicking Code.
Thanks