yourguide
Posts: 44
|
Posted: 07/22/2014, 10:04 AM |
|
I have an editable grid that I want to check to see the value in the database before I allow the update to happen.
I have found the help where they put code in the BeforeExecuteUpdate event that drops it out of the update and I am trying to get the value from the database using a dlookup in the server ON CLICK event of the submit button that populates a variable that the BeforeExecuteUpdate event checks.
Its not working.
My BeforeExecuteUpdate code:
if ($VarSONUM != '') {
$orders2->DataSource->CmdExecution = false;
}
My Button_Submit On Click DLookup:
global $DBATR_MySQL;
global $VarSONUM;
$Page = CCGetParentPage($sender);
$ccs_result = CCDLookUp(SalesOrderNo, SO_SalesOrderHeader, "UDF_AMAZONORDERNO=".CCToSQL($Container->ds->f("AmznOrderID"),ccsText), $Page->Connections["ATR_MySQL"]);
$ccs_result = strval($ccs_result);
$VarSONUM = $ccs_result;
Am I missing another way to do this that would actually work?
_________________
Independent, self-employed, web developer. |