I have problems taking individual data from an array. Searched the internet for about 2 hours with no succes. Code as followed:
$id_name = $this->name->Text;
$finder = prdtblRecord::finder();
$result = $finder->findAllByname($id_name);
$row_cnt = count($result);
if($row_cnt == 0)
{
$this->failed_id($param);
}
if($row_cnt == 1)
{
$this->id->Text = $result->id;
$this->name->Text = $result->name;
$this->adresse->Text = $result->adresse;
$this->plz->Text = $result->plz;
$this->ort->Text = $result->ort;
$this->firma->Text = $result->firma;
}
The problem refers to the $result->id
.
Error is Trying to get property of non-object
.
Thanks for reply and best regards.