(PHP ActiveX) Transition from Email.GetDt to Email.EmailDateStr
Provides instructions for replacing deprecated GetDt method calls with EmailDateStr. Note: This example requires Chilkat v11.0.0 or greater.
<?php
// For versions of Chilkat < 10.0.0, use new COM('Chilkat_9_5_0.Chilkat.Email')
$email = new COM("Chilkat.Email");
// ...
// ...
// ------------------------------------------------------------------------
// The GetDt method is deprecated:
// dateTimeObj is a Chilkat.CkDateTime
$dateTimeObj = $email->GetDt();
if ($email->LastMethodSuccess == 0) {
print $email->LastErrorText . "\n";
exit;
}
// ...
// ...
// ------------------------------------------------------------------------
// Do the equivalent using EmailDateStr.
// For versions of Chilkat < 10.0.0, use new COM('Chilkat_9_5_0.Chilkat.CkDateTime')
$dt = new COM("Chilkat.CkDateTime");
$dt->SetFromRfc822($email->EmailDateStr);
?>
|