Load from stream?

32 posts, 0 answers
  1. Qiping
    Qiping avatar
    4 posts
    Member since:
    Jul 2013

    Posted 27 Sep 2013 Link to this post

    Hey Kammen,

    I have tried to load the pdf file by using what you suggested:

    1.     Load a PDF file from stream:

    Stream str = App.GetResourceStream(newSystem.Uri("DocumentSource;component/Sample.pdf", System.UriKind.Relative)).Stream;

    this.pdfViewer.DocumentSource = newPdfDocumentSource(str);

    2.     Load a PDF file from Uri:

    this.pdfViewer.DocumentSource = newPdfDocumentSource(newSystem.Uri("DocumentSource;component/Sample.pdf", System.UriKind.Relative));


    Both methods need to create the instance new PdfDocumentSource. I have included the reference files:
    C:\Program Files (x86)\Telerik\RadControls for Silverlight Q2 2013\Binaries\Silverlight\Telerik.Windows.Controls.FixedDocumentViewers.dll
    C:\Program Files (x86)\Telerik\RadControls for Silverlight Q2 2013\Binaries\Silverlight\Telerik.Windows.Documents.Fixed.dll

    But the project still say the namespace for PdfDocumentSource could not be found. Any suggestions? Please see the attachment.

    Thanks

    Qiping
  2. Petya
    Admin
    Petya avatar
    975 posts

    Posted 02 Oct 2013 Link to this post

    Hi Qiping,

    Please refer to this thread where I answered your questions. If there is anything else unclear fell free to get back to us.

    Regards,
    Petya
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
Back to Top