Page 1 of 1

SubForm is a new entry.

Posted: Wed Apr 07, 2021 3:32 pm
by kknm
There are several BrowseForms on the main form, from which an array of values ​​is typed to fill the event log (:: subform).
Since this is a new record, it does not have a foreign key that is required for the new record.
How do I add a new entry to a subform - not PHP?

Re: SubForm is a new entry.

Posted: Wed Apr 07, 2021 4:06 pm
by kev1n
You could use the PHP AS event to add a record.

Re: SubForm is a new entry.

Posted: Wed Apr 07, 2021 4:22 pm
by kknm
I can write the necessary data to the database through the PHP procedure and update the form, but I was looking for a more elegant way. Can you describe in more detail how to do this in PHP AS?

Re: SubForm is a new entry.

Posted: Wed Apr 07, 2021 8:07 pm
by kev1n
Calling a PHP procedure or executing the code in AS would be pretty much the same.