CodeChargeMVP
Posts: 473
|
| Posted: 05/12/2011, 1:42 AM |
|
Hi,
I´m still finishing some small tasks on the screen with two record forms which record on the same table.
when the user record the fields from the second form, there´s one field on the first form than has to be recorded also in the database, I´ve found this useful thread:
http://forums.codecharge.com/posts.php?post_id=107300
http://ccselite.com/forums_topics_view.php?forum_id=2&forum_topic_id=84
As it explained, my idea is to run on the after insert event an php script which will update the database.
_________________
Best Regards
Entrepeneur | NT Consultant
|
 |
 |
CodeChargeMVP
Posts: 473
|
| Posted: 05/12/2011, 3:16 AM |
|
Here comes the solution:
global $DesemId;
$DesemId = mysql_insert_id();
//End Declare Variable
//Custom Code @155-2A29BDB7
$Consulta = "UPDATE Desembolsos SET DesGesRes=1 WHERE DesemId="."'".$DesemId."'". " AND InterId="."'".$desembolsos2->InterId->Value."'";
DbaUpdate("localhost","dgpolde","dgpolde","dgpolde1",$Consulta);
_________________
Best Regards
Entrepeneur | NT Consultant
|
 |
 |
|