retrieving previous record value of the same item in a block [message #560778] |
Tue, 17 July 2012 01:47 |
|
pgiftson
Messages: 3 Registered: July 2012 Location: Hyderabad
|
Junior Member |
|
|
Hi all,
i am creating a record with the items - S_No, Product_Name, Selling_Qty, Price.
checking the total qty (Tot_Qty) from the purchase stock - table1 and already sold out qty (Sold_Qty) of the product from table2.
consider the following values: Tot_Qty = 200; Sold_Qty = 50;
Now i create a first record of the form as follows: here on selecting the Product_name from LOV, will display the Selling_Qty item - which can be edited (Selling_Qty = Tot_Qty - Sold_Qty) and its price.
S_No Product_Name Selling_Qty Price
1. KeyBoard 50(150) 200
2. KeyBoard 30(150) 200
3. KeyBoard 50(150) 200
Note:
[value given within () are displayed automatically after selecting the prod]
My prob is, when i am entering next record, it displays the same 150 as qty, which have to be 100. After selecting the product from LOV, it should calculate & validate as shown below: which means, previous record value of Selling_Qty also have to be subtracted and displayed.
S_No Product_Name Selling_Qty Price
1. KeyBoard 50(150) 200
2. KeyBoard 30(100) 200
3. KeyBoard 50(70) 200
Is there any built-in functions to retrieve previous record value? Help me in this...
|
|
|
|
|
|
|
|
|