protected function btnUpdate_Click($strFormId, $strControlId, $strParameter)
{
$objControlToLookup = $this->GetControl($strParameter);
$dttDateTime = $objControlToLookup->DateTime;
// If a DateTime value is NOT selected or is INVALID, then this will be NULL
if ($dttDateTime) {
$this->lblResult->Text = 'QDateTime object:<br/>';
if (!$dttDateTime->IsDateNull()) {
$this->lblResult->Text .= 'Date: <strong>' . $dttDateTime->__toString('DDD MMM D YYYY') . '</strong><br/>';
} else {
$this->lblResult->Text .= 'Date: <strong>Null</strong><br/>';
}
if (!$dttDateTime->IsTimeNull()) {
$this->lblResult->Text .= 'Time: <strong>' . $dttDateTime->__toString('h:mm:ss z') . '</strong>';
} else {
$this->lblResult->Text .= 'Time: <strong>Null</strong>';
}
} else {
$this->lblResult->Text = 'QDateTime object: <strong>Null</strong>';
}
}