We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Some issues with PDFDocumentView

I working with PdFDocumentVIew.
I made simple code.


        PDFDocument = New PdfLoadedDocument(My.Resources.dummy_pdf_1)
        If PdfDocumentView1.LoadedDocument IsNot Nothing Then
            PdfDocumentView1.Unload()
        End If
        PdfDocumentView1.Load(PDFDocument)

        Dim page As PdfLoadedPage

        page = PDFDocument.Pages(PdfDocumentView1.CurrentPageIndex - 1)

        Dim g As PdfGraphics = page.Graphics
        Dim pen As New PdfPen(Color.Red)

        g.DrawLine(pen, New Point(100, 100), New Point(200, 100))
        ' Invalidate()
        PdfDocumentView1.Refresh()

It's working like I intend but when i divide code to parts I received error  which i cant solve.




Every test is launched on "clear" app.
When i use ATTEMPT3, its working.
When I use ATTEMPT1, ATTEMPT2 the red line doesnt appear.
When I use ATTEMPT1, ATTEMPT2, ATTEMPT3 I received error which is posted above.


Also I cant catch any event on PDFDocumentView, I click everywhere on control and PdfDocumentView1.MouseClick event didnt raise.


Attachment: PDFDocumentViewTest_571ad430.zip

1 Reply

AS Aravinth Sampath Syncfusion Team March 7, 2017 04:08 PM UTC

Hi Lukasz, 

A support incident to track the status of reported issue “PdfDocumentView crashes while loading PDF document in provided sample, has been created under your account. Please log on to our support website to check for further updates.  
 
 
Regards, 
Aravinth 


Loader.
Live Chat Icon For mobile
Up arrow icon