Sample code for 30+ languages & platforms
Unicode C

Replace Deprecated GetExpirationDt

Shows how to replace the deprecated GetExpirationDt method.

Chilkat Unicode C Downloads

Unicode C
#include <C_CkCacheW.h>
#include <C_CkDateTimeW.h>

void ChilkatSample(void)
    {
    HCkCacheW cache;
    const wchar_t *cache_item_key;
    HCkDateTimeW dt1;
    HCkDateTimeW dt2;

    cache = CkCacheW_Create();

    //  ....
    //  ....

    cache_item_key = L"xyz";

    //  Instead of this:
    dt1 = CkCacheW_GetExpirationDt(cache,cache_item_key);
    CkDateTimeW_Dispose(dt1);

    //  Do this:
    dt2 = CkDateTimeW_Create();
    CkDateTimeW_SetFromRfc822(dt2,CkCacheW_getExpirationStr(cache,cache_item_key));


    CkCacheW_Dispose(cache);
    CkDateTimeW_Dispose(dt2);

    }