Clob or memptr and System.IO.Stream

Posted by DenDuze on 05-Jan-2017 03:29


I want to use the Telerik RadPdfViewer with the LoadDocument(System.IO.Stream) but my data is available as a clob.
Is it possible to use the System.IO.Stream with a clob??
I tried a few things but always got stuck, maybe someone can help with this.

NB: I know I can create the pdf from the clob first on file and the load that one with LoadDocument(fileName) but I would prefer to use the quicker LoadDocument(System.IO.Stream) but how to load that Stream-object with the data from the clob (or memptr)??

All Replies

Posted by Vasantha on 09-Jan-2017 01:02

Hi DenDuze,

Please post this questions in Telerik forum (



Posted by DenDuze on 09-Jan-2017 02:21

Hi Vasantha,

Ok, will try that but because this is a Progress clob/memptr I asked this here.

On a Telerik forum I can expect some answers that will be correct but if I can transform those then to Progress is another question.

Fot the moment I use LoadDocument (fileName) and this works also very quick so it's Ok but still I wonder if this approach is also possible


Posted by DenDuze on 09-Jan-2017 02:33

Oeps, I just noticed that this is placed in RollBase forum.

Can some moderator move this thread to the correct forum? (.net, OE, ??)

Posted by jquerijero on 09-Jan-2017 12:53

Copy the clob to longchar

Use System.Convert to convert the longchar and save it to System.Bytes[]

Create an instance of System.IO.MemoryStream by passing System.Bytes[]

You can use the memory stream as input to LoadDocument

Posted by scott_auge on 09-Jan-2017 13:05

Some answers are very windows-centric.  There are many operating systems out there.  :)

Posted by jquerijero on 09-Jan-2017 13:08

Not so sure if there are any non-window Telerik controls though.

Posted by scott_auge on 09-Jan-2017 14:29

There is for Linux ( ) but I don't know of any for AIX, MP-RAS, HP-UX, or SCO (if anyone uses that since the lawsuit.)  Most of these are still "supported" but to varying degrees.

When I got involved with Progress, the promise was "same code - different systems."  Heck, I remember when Progress had an X-Window development system.

These days, I see java taking that range of functionality.  Heck, even PHP runs on Mac OS X.

Meanwhile Progress keeps hemming it's self in on fewer operating systems.

Just a rant.  Just wanted to point out all answers are not as general as others.

This thread is closed