Sample code for 30+ languages & platforms
Objective-C

Transition from Crypt2.LastJsonData to Crypt2.GetLastJsonData

Provides instructions for replacing deprecated LastJsonData method calls with GetLastJsonData.

Chilkat Objective-C Downloads

Objective-C
#import <CkoCrypt2.h>
#import <CkoJsonObject.h>

BOOL success = NO;

CkoCrypt2 *crypt2 = [[CkoCrypt2 alloc] init];

//  ...
//  ...

//  ------------------------------------------------------------------------
//  The LastJsonData method is deprecated:

CkoJsonObject *jsonObj = [crypt2 LastJsonData];
if (crypt2.LastMethodSuccess == NO) {
    NSLog(@"%@",crypt2.LastErrorText);
    return;
}

//  ...
//  ...

//  ------------------------------------------------------------------------
//  Do the equivalent using GetLastJsonData.
//  Your application creates a new, empty JsonObject object which is passed 
//  in the last argument and filled upon success.

CkoJsonObject *jsonOut = [[CkoJsonObject alloc] init];
[crypt2 GetLastJsonData: jsonOut];
if (success == NO) {
    NSLog(@"%@",crypt2.LastErrorText);
    return;
}