Skip to main content
January 12, 2016
Question

while sending the document through API I am getting "Object Reference error not set to instance of an object" error

  • January 12, 2016
  • 1 reply
  • 589 views

FileStream file = getTestPdfFile(fileName);

            com.echosign.secure.FileInfo[] fileInfos = new com.echosign.secure.FileInfo[1];

         

            fileInfos[0] = new com.echosign.secure.FileInfo();

            fileInfos[0].fileName = fileName;

            Byte[] bytes = File.ReadAllBytes(".\\" + fileName);

            String filed = Convert.ToBase64String(bytes);

            byte[] filedata = Convert.FromBase64String(filed);

            fileInfos[0].file = filedata;

            SenderInfo senderInfo = new SenderInfo();

            senderInfo = null;

            RecipientInfo[] recipientInfo = new RecipientInfo[2];

            RecipientInfo recipientEmail = new RecipientInfo();

            recipientEmail.email = recipient;

            recipientEmail.fax = null;

            recipientEmail.role = RecipientRole.SIGNER;

            recipientEmail.roleSpecified = true;

            recipientInfo[0] = recipientEmail;

            DocumentCreationInfo documentInfo = new DocumentCreationInfo();

            documentInfo.recipients = recipientInfo;

            documentInfo.name = "Testing Echo";

            documentInfo.fileInfos = fileInfos;

            documentInfo.signatureType = SignatureType.ESIGN;

            documentInfo.signatureFlow = SignatureFlow.SENDER_SIGNATURE_NOT_REQUIRED;

  ES.sendDocument(apiKey, senderInfo, documentInfo);

This topic has been closed for replies.

1 reply

Inspiring
January 26, 2016

Hello Vinod,

It seems that you were using sendDocument API call. Can you inbox me you registered email address with which you were trying to make API calls so that I can check if the call was ever made to E-Sign or not?

Regards,

-Rijul

February 15, 2016

Hi Raj,

Can you Please look into my code which I have posted and say what is the problem in that.

Thanks in advance

Regards,

Vinod Kumar.