Sample code for 30+ languages & platforms
Node.js

Transition from Email.GetAttachedMessage to Email.GetAttachedEmail

Provides instructions for replacing deprecated GetAttachedMessage method calls with GetAttachedEmail.

Chilkat Node.js Downloads

Node.js
NODEJS_PRELUDE

function chilkatExample() {

    var success = false;

    var email = new chilkat.Email();

    //  ...
    //  ...
    var index = 0;

    //  ------------------------------------------------------------------------
    //  The GetAttachedMessage method is deprecated:

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

    //  ...
    //  ...

    //  ------------------------------------------------------------------------
    //  Do the equivalent using GetAttachedEmail.
    //  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.GetAttachedEmail(index,emailOut);
    if (success == false) {
        console.log(email.LastErrorText);
        return;
    }


}

chilkatExample();