NetTalk Central

Author Topic: Confused with server side value sent  (Read 3186 times)

jorgemir

  • Jr. Member
  • **
  • Posts: 71
    • View Profile
    • Email
Confused with server side value sent
« on: March 30, 2011, 10:25:50 PM »
Hi.
This code I put into send value to server:

Det:Total=Det:Cantidad*Det:PVP
                       /\                   /\
These are file fields.
Do I have to use p_web.gsv('Det:cantidad') in order to get the real valu? I already have this fields primed and I see they are written to file, but the Det:Total, which is not touched at all. In this case, what  is the correct construction of the statement¿
Thanks
Jorge

kevin plummer

  • Hero Member
  • *****
  • Posts: 1195
    • View Profile
    • Production Accounting and Software Payroll
Re: Confused with server side value sent
« Reply #1 on: March 30, 2011, 10:33:01 PM »
Yes you must use p_web unless you move your code to the Validate Embed on Save it should work without p_web.

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11245
    • View Profile
Re: Confused with server side value sent
« Reply #2 on: March 30, 2011, 11:49:35 PM »
The key is to save the Det:Total in the session queue after the calculation.
ie

Det:Total=Det:Cantidad*Det:PVP
p_web.SetSessionValue('Det:Total',DetTotal)

Cheers
Bruce