Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Accessing Compute Expression

Status
Not open for further replies.

katghoti

Programmer
Jun 27, 2016
1
US
I am trying to gain access to two fields on my datawindow. One is in the Footer called "total" Currently is has a Compute Expression of sum(if(pyd_pretax='E',0,pyd_amount) for all) I do some checking on the datatable for some conditions and if the condition is met, I need to change the value of the total field.

The code I am using is:

if ll_tarifftotal > 0 then
if ll_tarifftotal <= ll_order total then
dw_triptab.object.total.setitem(1,"ll_tarifftotal","ll_ordertotal")
end if
end if

I am having problems changing the value of the "total" field in the footer of the data window.

Any suggestions?

Thanks.
 
You will either have to modify the expression which comes up with the total (the 'sum...' from your example) or you need to change the field to a calculated value and set it based on your business rules.

Matt

"Nature forges everything on the anvil of time"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top