I have a Multimedia Component with a multimedia type .pdf. Is it possible to read the content of the PDF uploaded as binary file from the Multimedia Component?

EDIT Suppose we have to search for a word testparameter available in the PDF content. Then to achieve this we need to access to the PDF content, only then we can find out whether testparameter is matching in the PDF content or not.

  • Is it possible to be more clear with the question? What do you mean with "read"? Where? Apr 22, 2014 at 7:18
  • @RaúlEscudero i have edited my question, i hope i made myself clear. I need to find out wheather a specific word is present in PDF content uploaded as binary file in multimedia compoenent. Apr 22, 2014 at 7:42
  • you haven't answered @RaúlEscudero question. WHAT is the context of your problem? you want to do in TOM.NET or using Core Service? Apr 22, 2014 at 7:43
  • @SaurabhGangwar Is it possible using Core Services? Apr 22, 2014 at 7:45
  • it is possible using both TOM.NET and Core-Service. which one to be used depends on the context of your problem. Apr 22, 2014 at 7:47

2 Answers 2


CoreService provides client StreamDownloadClient to download files from Content Manager.

You can use following code to get the binary content as a stream, and once you have stream you can read the stream to find the text.

StreamDownloadClient streamDownloadClient = new StreamDownloadClient();

Stream tempStream = streamDownloadClient.DownloadBinaryContent(“TCM:X-Y-Z”);

Update: as suggested by Peter in comments, use proper endPointConfigurationName with StreamDownloadClient.

  • 3
    Indeed. Note that this is a different client, which uses a different binding (due to the streaming nature of the functionality). So you need to make sure you have that binding available in your configuration file (or code if you are setting it up programmatically) Apr 22, 2014 at 8:37

I try to download the multimedia component using below code and I below error.

StreamDownloadClient streamDownloadClient = new StreamDownloadClient();

Stream tempStream = streamDownloadClient.DownloadBinaryContent(“TCM:X-Y-Z”);

System.ServiceModel.Security.MessageSecurityException: 'The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'Negotiate,NTLM'.'

looking for solution this issue in SDL Web 8.5.

  • Please remove this answer and raise it as a separate question with reference to this question?
    – Velmurugan
    Feb 7, 2019 at 8:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.