Free Support Forum - groupdocs.com

Black pages in GroupDocs .NET Viewer v18.3.0.0

When viewing certain pdf files converted to jpeg images by GroupDocs .NET Viewer, occasionally some pages show with black background. Anything I can do about this?

Thanks, Denis

@DenisDavid,

Thanks for using GroupDocs.Viewer and sharing your concerns with us. In order to investigate your reported issue, we would require the following from you.

  • Problematic PDF document
  • Sample code you are using to render the document

We shall be looking forward to your response.

Dear Usman,

Thanks for your reply.
I have sent the sample files as private post to you.

This is my sample code:

 Blob blob = System.Threading.Tasks.Task.Run(() => GetDocumentBlob(DocumentID)).Result; // GetDocumentBlob is a custom function to retrieve the document from our DMS
 FileStream stream = blob.File.OpenRead();

        List<PageImage> Images = imageHandler.GetPages(stream, options);
        List<ImageInfo> contents = new List<ImageInfo>();

        foreach (PageImage image in Images)
        {
            //Save each image at disk
            string imgname = image.PageNumber + "_" + Path.GetFileNameWithoutExtension(DocumentName);
            imgname = Regex.Replace(imgname, @"\s+", "_");
            Utilities.SaveAsImage(image.PageNumber + "_" + DocumentName, image.Stream);
            ImageInfo imageInfo = new ImageInfo();
            imageInfo.ImageUrl = HttpContext.Current.Request.Url.GetLeftPart(UriPartial.Authority) + "/groupdocs/data/output/images/" + imgname + ".Jpeg?" + Guid.NewGuid().ToString();
            imageInfo.PageNmber = image.PageNumber;
            imageInfo.HtmlContent = @"<div class='image_page'><img width='100%' src='" + imageInfo.ImageUrl + "' /></div>";
            contents.Add(imageInfo);
        }

        stream.Dispose();
 return contents;

Thanks indeed for your support.

Best regards,

Denis

@DenisDavid,

Thanks for sharing the required details. We are able to reproduce your reported issue at our end. We have logged this issue in our Issue Tracking System (with ID: VIEWERNET-1558) for further investigation. We’ll keep you informed in case of any updates.

Dear Usman,

Thanks for your quick reply.

Could you please kindly give me a rough estimate by when a hotfix will be available.
As I need to get the viewer running properly as soon as possible I would like to ask if there is an option to subscribe to a premium support plan to accelerate a solution for the issue.

Thanks indeed for your help.

Best regards,

Denis

@DenisDavid,

Thanks for coming back to us.

I am afraid that we can not provide any ETA at the moment. However, you can prioritize the issue in our the issue tracking system by availing paid support. For more details on paid support, please visit here.