Sample code for 30+ languages & platforms
Node.js

Transition from Email.Clone to Email.MakeCopy

Provides instructions for replacing deprecated Clone method calls with MakeCopy.

Chilkat Node.js Downloads

Node.js
NODEJS_PRELUDE

function chilkatExample() {

    var success = false;

    var email = new chilkat.Email();

    //  ...
    //  ...

    //  ------------------------------------------------------------------------
    //  The Clone method is deprecated:

    // emailObj: Email
    var emailObj = email.Clone();
    if (email.LastMethodSuccess == false) {
        console.log(email.LastErrorText);
        return;
    }

    //  ...
    //  ...

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

    var emailOut = new chilkat.Email();
    success = email.MakeCopy(emailOut);
    if (success == false) {
        console.log(email.LastErrorText);
        return;
    }


}

chilkatExample();