API to show / hide the Annotations toolbar

Is there an API to show / hide the Annotations toolbar?  I have added a custom toolbar and would like to use just the Annotations toolbar of the SfPdfViewer.

Regards,
Arthur



16 Replies

AA Akshaya Arivoli Syncfusion Team May 14, 2020 12:29 PM UTC

Hi Arthur, 

Thank you for contacting Suncfusion support. 

We can enable/disable the Annotation Toolbar using the EnableAnnotationToolbar toolbar API available in the PDF Viewer. 

<SfPdfViewer @ref="PDFViewer" DocumentPath="PDF_Succinctly.pdf" ServiceUrl="https://ej2services.syncfusion.com/production/web-services/api/pdfviewer" EnableAnnotationToolbar="false" Height="100%" Width="100%" >    
</SfPdfViewer> 


Please try it and revert us with more details about your requirement, use case scenario and if you need any further assistance. 

Regards, 
Akshaya 



AB Arthur Butler May 14, 2020 02:59 PM UTC

EnableAnnotationToolbar seems to just enable or disable the Annotation button on the main toolbar.  What I am wanting to do is to have an API that will show or hide the complete Annotation Toolbar - basically, the same functionality as the Annotation button on the main toolbar.  And I want do do this while setting EnableToolbar = false.

Regards,
Arthur


AA Akshaya Arivoli Syncfusion Team May 17, 2020 02:53 PM UTC

Hi Arthur , 

We are currently checking on the query with the provided details. We will analyze further and update you with more details on May 18th, 2020 

Regards, 
Akshaya 



SM Selvakumar Murugan Syncfusion Team May 18, 2020 05:03 PM UTC

Hi Arthur, 
We have already provided the support to show and hide the annotation Toolbar. But, further checking we have found some issues on this function. Currently we have validating this issue at our end. We will update further details on 20th May 2020.

Regards,
Selvakumar 



AA Akshaya Arivoli Syncfusion Team May 20, 2020 09:36 AM UTC

Hi Arthur, 
 
We have Confirmed that the "ShowAnnotationToolbar not working properly" is a defect and logged the defect report for the same. The fix for the issue will be included in out weekly Nuget release on 3rd June 2020. You can track the status using the below link,

https://www.syncfusion.com/feedback/14541/showannotationtoolbar-method-not-working-properly
 
 
Regards, 
Akshaya  



AB Arthur Butler May 21, 2020 06:44 PM UTC

Will I be able to show the AnnotationToolbar while showing my custom toolbar with EnableToolbar="false" ?


AA Akshaya Arivoli Syncfusion Team May 22, 2020 02:00 PM UTC

Hi Arthur, 

Yes, we can show the AnnotationToolbar when EnableToolbar is false. But as mentioned earlier we are facing the issue "ShowAnnotationToolbar not working properly" and the fix will be included in our weekly NuGet release on 3rd June 2020 


Regards, 
Akshaya  



AB Arthur Butler May 27, 2020 06:15 AM UTC

Thank you for the update.


AB Arthur Butler June 3, 2020 07:22 AM UTC

I am testing in v18.1.0.55.  EnableAnnotationToolbar does NOT show/hide the annotation toolbar.


AA Akshaya Arivoli Syncfusion Team June 3, 2020 11:15 AM UTC

Hi Arthur, 

Sorry for the inconvenience caused. We have fixed the reported issue but the fix for the issue was not included in our latest weekly release due to technical issue. However, it will be included in our upcoming weekly NuGet release on June 10, 2020. 

Regards, 
Akshaya 



AB Arthur Butler June 3, 2020 03:22 PM UTC

Thank you for the update.


SM Selvakumar Murugan Syncfusion Team June 10, 2020 06:16 AM UTC

Hi Arthur,

We have fixed the reported issue "ShowAnnotation Toolbar not working properly" and the fix for the issue was included in our latest weekly NuGet release v18.1.0.56. Kindly upgrade to the latest version to get the issue resolved. please find the API details and Code snippet below.


Code Snippet:  
PDFviewer.GetToolbar().ShowAnnotationToolbar(true); 
 
API Details: 

           API NAME  (Method) 

       TYPE 

                     Descriptions 

ShowAnnotationToolbar 

     Boolean 
If set as true, show the annotation Toolbar. 

If set as false, hide the annotation Toolbar. 
 
Regards,
Selvakumar 



AB Arthur Butler June 14, 2020 06:26 AM UTC

Thank you, this works well.


AA Akshaya Arivoli Syncfusion Team June 15, 2020 06:24 AM UTC

Hi Arthur, 

Thank you for your update. We are glad to know that the reported issue is resolved. Please contact us if you need any assistance in future. 

Regards, 
Akshaya 



KS kai steinmann replied to Akshaya Arivoli June 15, 2023 06:10 PM UTC

Thank you!  That works.  Is there a similar call to open the "Handwritten Initials" window?


Attachment: Screenshot_Initials_262a8503.zip


VV Visvesvar Venkatesan Syncfusion Team June 20, 2023 07:05 AM UTC

At present, Blazor PDF Viewer does not offer support for initials. Nevertheless, I can provide you with the code snippet that allows you to open handwritten signature dialog alone directly.


Code Snippet:


<div class="control-section">

     <SfPdfViewerServer @ref="viewer" DocumentPath="@DocumentPath" Height="640px" Width="100%">

        <PdfViewerEvents DocumentLoaded="DocumentLoad"></PdfViewerEvents>

    </SfPdfViewerServer>

</div>

@code {

    SfPdfViewerServer viewer;

    public async void DocumentLoad(LoadEventArgs args)

    {

        await viewer.SetAnnotationModeAsync(AnnotationType.HandWrittenSignature);

    }

    private string DocumentPath { get; set; } = "wwwroot/data/pdfviewer/hand-written-signature.pdf";

}

 



Online sample: https://blazor.syncfusion.com/demos/pdf-viewer/handwritten-signature?theme=fluent


Kindly try this and let us know if you have any concerns.


Loader.
Up arrow icon