NetTalk Central

Author Topic: PR37 Default From Action  (Read 3130 times)

Alberto

  • Hero Member
  • *****
  • Posts: 1873
    • MSN Messenger - alberto-michelis@hotmail.com
    • View Profile
    • ARMi software solutions
    • Email
PR37 Default From Action
« on: May 04, 2009, 03:14:08 PM »
Hi,

Using the Default form action to Change and the Unique key field value to USU:ID
and seting the USU:ID in the Procedure setup like:

   USU:ID = p_web.gsv('login_id')
   Access:Users.Fetch(USU:xID_USU)
   p_web.ssv('USU:ID',USU:ID)

You see the form with the correct record values but if you edit some field and click Save the new field value is not saved.

Thanks
Alberto


-----------
Regards
Alberto

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: PR37 Default From Action
« Reply #1 on: May 04, 2009, 08:39:24 PM »
For starters I'd say you can drop your code and replace the template setting with
p_web.gsv('login_id')
ie use this as the "key component value".

Secondly - embedding code in procedure startup like this is not a good idea. That code runs multiple times, and usually it's better off in the specific routine/p[lace where it is needed.

Cheers
Bruce