jumpToBookmark method

void jumpToBookmark(
  1. PdfBookmark bookmark

Navigates to the specified bookmark location in a PDF document.

Using this method, the SfPdfViewer navigates to the specified PdfBookmark location in a PDF document. If the specified bookmark location is wrong, then the navigation will not happen and the older page location will be retained.

  • bookmark - required - The bookmark location to which the SfPdfViewer should navigate to.

Returns null.

This example demonstrates how to navigate to the specified bookmark location.

class MyAppState extends State<MyApp>{
late PdfViewerController _pdfViewerController;
late PdfBookmark _pdfBookmark;

 void initState(){
   _pdfViewerController = PdfViewerController();

 Widget build(BuildContext context) {
   return MaterialApp(
     home: Scaffold(
       appBar: AppBar(
          title: Text('Syncfusion Flutter PdfViewer'),
          actions: <Widget>[
                icon: Icon(
                   color: Colors.white,
                onPressed: () {
       body: SfPdfViewer.asset(
         controller: _pdfViewerController,
         onDocumentLoaded: (PdfDocumentLoadedDetails details){
            _pdfBookmark = details.document.bookmarks[0];


void jumpToBookmark(PdfBookmark bookmark) {
  _pdfBookmark = bookmark;
  _notifyPropertyChangedListeners(property: 'jumpToBookmark');