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

Exception loading PDF File - System.NullReferenceException: Object reference not set to an instance of an object


Captured following exception in production.

Syncfusion library version used: 16.4.0.54

Device
Galaxy S6

OS
Android 7.0

PdfLoadedRadioButtonItem.GetItemValue ()
System.NullReferenceException: Object reference not set to an instance of an object

  • PdfLoadedRadioButtonItem.GetItemValue ()
  • PdfLoadedRadioButtonItem.get_Value ()
  • ScrollViewEx.AddRadioButtonField (Syncfusion.Pdf.Parsing.PdfLoadedRadioButtonItem radioButtonField, Syncfusion.SfPdfViewer.XForms.Droid.TransparentCanvas canvas, System.Int32 pageIndex, System.Int32 indexInGroup)
  • ScrollViewEx.AddExistingFormFields (System.Int32 pageIndex)
  • LinearLayoutEx.RenderPages ()
  • HorizontalScrollViewEx.RenderPages ()
  • ScrollViewEx.RenderPages ()
  • CountDownTimerEx.OnTick (System.Int64 millisUntilFinished)
  • CountDownTimer.n_OnTick_J (System.IntPtr jnienv, System.IntPtr native__this, System.Int64 millisUntilFinished)
  • (wrapper dynamic-method) System.Object.115(intptr,intptr,long)

  • 3 Replies

    SS Sathish Sivakumar Syncfusion Team May 3, 2019 07:32 AM UTC

    Hi Vadim, 
     
    Greetings from Syncfusion. 
     
    We tried to reproduce the issue “Application crashes with System.NullReferenceException” in our side, but the PDF Document is displayed properly in SfPdfViewer with v16.4.0.54. We suspect that the issue is specific to the PDF document containing form fields loaded into SfPdfViewer. We recommend you to update the SfPdfViewer to the latest version and share the following details if you still face the same issue. 
     
    1. PDF document with which the issue could be reproduced.
    2. Modify/Simple sample to reproduce the issue.
    3. Replication procedure to reproduce the issue.
     
    Please find the sample with which we tried to reproduce the reported issue in our side. 


    Regards, 
    Sathish 



    PR Pure Ray June 12, 2019 02:03 PM UTC

    Hi, SyncFusion-eer.

    We are also having the same problem. Do you have an update or a workaround to share with us?

    Xamarin.Forms 3.6.0.344457
    Syncfusion.Xamarin.SfPdfViewer 17.1.0.51

    Please and thank you.

    Regards.
    Ray



    SS Sathish Sivakumar Syncfusion Team June 13, 2019 09:11 AM UTC

    Hi Ray, 

    Greetings from Syncfusion.  
      
    We tried to reproduce the issue “Application crashes with System.NullReferenceException” in our side, but the PDF Document is displayed properly in SfPdfViewer with v17.1.0.51. We suspect that the issue is specific to the PDF document containing form fields loaded into SfPdfViewer. Please find the sample with which we tried to reproduce the reported issue in our side.  


    Kindly share the following details to analyze more on the reported issue and assist you with the better solution. 
    • PDF document with which the issue could be reproduced.
    • Modify/Simple sample to reproduce the issue.
    • Replication procedure to reproduce the issue.
    Regards,  
    Sathish 


    Loader.
    Live Chat Icon For mobile
    Up arrow icon