marcocarrieri
Posts: 7
|
| Posted: 04/12/2010, 10:25 PM |
|
Sorry for English.
I'm trying to use the above function but reflected problems.
function pagine_pagine_figliadi_BeforeShow(& $sender)
{
$pagine_pagine_figliadi_BeforeShow = true;
$Component = & $sender;
$Container = & CCGetParentContainer($sender);
global $pagine; //Compatibility
global $DBlamiaconnessione; $valore=CCDLookUp("pagine_titolo","pagine","pagine_figliadi=".$pagine->pagine_figliadi->value, $DBlamiaconnessione);
$pagine->pagine_figliadi->Text=$valore;
return $pagine_pagine_figliadi_BeforeShow;
}
My connection is named lamiaconnessione and if the global is defined with another name get error. Ok....
But $pagine->pagine_figliadi->Text non assume CCDLookUp value...
And if in a CCDLookUp function write random words not see as error...
$valore=CCDLookUp("pagine_titolo","pafsdfsd fsd gine","pagine_figliadi=".$pagine->pagine_figliadi->value, $DBlamiaconnessione);
Why?
Is not correct usage?
Excuse for my english...
|
 |
 |
datadoit
|
| Posted: 04/13/2010, 7:58 AM |
|
You should try using the built-in DLookup action instead of your own
Custom Code. Fill in the blanks for the Properties (encase in quotes),
then see what it produces for you.
From what I see in your post sample, using the DLookup action should
work fine for you.
Expression: "pagine_titolo"
Domain: "pagine"
Criteria: "pagine_figliadi=".$Component->GetValue()
Connection: lamiaconnessione <---- Select this from listbox
Convert result to: Text (or whatever)
Type of Target: Control
Target: pagine_figliadi <---- Select this from listbox
|
|
|
 |
marcocarrieri
Posts: 7
|
| Posted: 04/13/2010, 11:46 AM |
|
Ok i try... but why the function not return a error in use it in wrong mode?
$valore=CCDLookUp("pagine_titolo","table not exist","pagine_figliadi=".$pagine->pagine_figliadi->value, $DBlamiaconnessione);
|
 |
 |
|