NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: rupertvz on January 19, 2012, 04:46:50 AM

Title: Change value before insert / save
Post by: rupertvz on January 19, 2012, 04:46:50 AM
Hi Guys,

I have a NetWebBrowse with a NetWebForm
The user is selecting some values on the form
I'd like to change / overwrite some values, just before the record is finally inserted / saved to the database from the form.

What will be the best embed to use in the form for the above ...?

Thanks
Rupert
Title: Re: Change value before insert / save
Post by: rupertvz on January 19, 2012, 04:53:59 AM
I think I found the correct embed for this;

PREINSERT, after END
PREUPDATE, after END

?
Title: Re: Change value before insert / save
Post by: Bruce on January 19, 2012, 05:24:58 AM
PreInsert and PreUpdate happen when the form is opened.
(This is where the items on the Priming tab go)

If you want to do it after the click on the save button, before the record is written, then use the ValidateRecord routine.

Cheers
Bruce