Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Why doesn't latest version of pdf have a visible signature, only blank fields

Guest
Jan 21, 2015 Jan 21, 2015

I'm C# user and tried both createUrlWidget and createPersonalUrlWidget to send a test document, and after it signed by signer, I used both getLatestDocument and getDocuments, but only get a pdf without seeing signature like this:

2015-01-21_1418.png

I can get signed doc using the link in email sent to signer:

2015-01-21_1409_001.png

So, I'm confused, can anybody answer me where did I missed?

1. the method I used to create url widget:

public static bool createUrlWidget(string fileName)

        {

            FileStream file = File.OpenRead(fileName);

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

            fileInfos[0] = new com.echosign.secure.FileInfo(fileName, null, file);

            SenderInfo senderInfo = null;

            //string[] recipients = new string[1];

            //recipients[0] = recipient;

            RecipientInfo[] recipients = new RecipientInfo[1];

            recipients[0] = new RecipientInfo();

            recipients[0].email = "myemail@hotmail.com";

            RecipientRole role = new RecipientRole();

            role = RecipientRole.SIGNER;

            recipients[0].role = role;

            WidgetCreationInfo widgetInfo = new WidgetCreationInfo();

            widgetInfo.name = "Test Docx";

            widgetInfo.fileInfos = fileInfos;

            //widgetInfo.counterSigners = recipients;

            WidgetPersonalizationInfo personInfo = new WidgetPersonalizationInfo();

            personInfo.comment = "Test sign of doc";

            personInfo.email = recipients[0].email;

            personInfo.reusable = false;

            UrlWidgetCreationResult result = ES.createPersonalUrlWidget(APIKey, senderInfo, widgetInfo, personInfo);// ES.createUrlWidget(APIKey, senderInfo, widgetInfo);

            if (result.success)

            {

                DocumentKey2 = result.documentKey;

                urlWidgetReturn = result.url;

            }

            else

                return false;

            return true;

        }

2. the method I get the documents, there's only 1 content in returned DocumentContent[]:

public static void getDocuments(string documentKey)

        {

            GetDocumentsOptions opts = new GetDocumentsOptions();

            //opts.versionKey = "latest version";

            //opts.participantEmail = "myemail@hotmail.com";

            opts.combine = true;

            opts.attachSupportingDocuments = true;

            GetDocumentsResult result  = ES.getDocuments(APIKey, documentKey, opts);

            if (result.success)

            {

                DocumentContent[] contents = result.documents;

                foreach (DocumentContent dc in contents)

                {

                    FileStream file = File.OpenWrite(string.Format("c:\\{0}.pdf", Guid.NewGuid()));

                    file.Write(dc.bytes, 0, dc.bytes.Length);

                }

            }

               

        }

This is my first time to use this api, so maybe I missed some important steps to cause this. I appreciate anybody which could see this and help me.

Thanks a lot!

Kenny

403
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 21, 2015 Jan 21, 2015
LATEST

I figured it out myself, I should use the shorter keys parsing from formDataCsv in GetFormDataResult to retrieve the latest version.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines