dhruv_x0
26th October 2010, 08:34
Hi...
How can i make a validation in multimain session such that in satellite their is a field 'price' and in Header their is 'Amount'. then validation will be like line wise sum of price in satellite should not be greater than Amount.
sameer.don
26th October 2010, 09:20
Visit this thread:
http://www.baanboard.com/baanboard/showthread.php?t=59297
I have poseted a code which I used for similar validations.
Check if it helps you.
MilindV
26th October 2010, 11:37
Hi Dhruv,
You can use the function enable.save.on.occ.change()
This function to force the 4GL Engine to save an occurrence at the time the user selects or moves to another occurrence.
Then in DAL2, use field hook field.is.valid() you can query to find out sum of all prices.
so chk will be like, sum from query + curr price compared with amount
If you declare the main table of header session in DAL/DAL2 of satellite session, then value of ‘amount’ field in header will be available in DAL of satellite session.
Regards,
MilindV