save state of PdfLoadedDocument

I would like to implement the tab concept:

  1. Open the document and do some actions.
  2. Open another document and do some actions.
  3. Navigate back to the first one, to the same state where I was before I left.
Is it possible to do this somehow using a single SfPdfViewerControl? Every time I try to set the previously opened PdfLoadedDocument back to SfPdfViewerControl I get an error message: 'System.NullReferenceException: 'Object reference not set to an instance of an object.'



1 Reply

MA ManojKumar Arumugasamy Syncfusion Team February 6, 2024 08:44 AM UTC

Hello Cole,

We appreciate your inquiry and would like to gather more details about your requirements. It seems you're using Tabview to switch between two tabs while attempting to utilize a single PDfViewer control. Please note that for loading PDFs on different tabs, you'll need multiple instances of the PdfViewer control (one for each tab). It's essential to save the previous stream before switching to another tab and load the saved stream when switching back.

Could you kindly provide more information about the specific functionality you are trying to achieve with these actions? We would greatly appreciate it if you could elaborate on your requirements. Additionally, if possible, sharing a simple sample would be helpful in better understanding your needs.

Regards,

Manoj Kumar.


Loader.
Up arrow icon