Node.js
Node.js
Transition from Crypt2.LastJsonData to Crypt2.GetLastJsonData
Provides instructions for replacing deprecated LastJsonData method calls with GetLastJsonData.Chilkat Node.js Downloads
NODEJS_PRELUDE
function chilkatExample() {
var success = false;
var crypt2 = new chilkat.Crypt2();
// ...
// ...
// ------------------------------------------------------------------------
// The LastJsonData method is deprecated:
// jsonObj: JsonObject
var jsonObj = crypt2.LastJsonData();
if (crypt2.LastMethodSuccess == false) {
console.log(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.
var jsonOut = new chilkat.JsonObject();
crypt2.GetLastJsonData(jsonOut);
if (success == false) {
console.log(crypt2.LastErrorText);
return;
}
}
chilkatExample();