CkPython
CkPython
Transition from Cert.GetValidToDt to Cert.ValidToStr
Provides instructions for replacing deprecated GetValidToDt method calls with ValidToStr.Chilkat CkPython Downloads
import sys
import chilkat
cert = chilkat.CkCert()
# ------------------------------------------------------------------------
# The GetValidToDt method is deprecated:
# ckdt1 is a CkDateTime
ckdt1 = cert.GetValidToDt()
if (cert.get_LastMethodSuccess() == False):
print(cert.lastErrorText())
sys.exit()
# ...
# ...
# ------------------------------------------------------------------------
# Do the equivalent using the ValidToStr property
ckdt2 = chilkat.CkDateTime()
ckdt2.SetFromRfc822(cert.validToStr())