PDF Viewer click control

Hi,

I would like to know if there is any way to know where the user clicks on a pdf using the Syncfusion PDF Viewer to later be able to add forms on the site chosen by a user.


Thanks in advance.


5 Replies

VS Vasugi Sivajothi Syncfusion Team June 24, 2021 11:44 AM UTC

Hi Ivan, 
  
Thank you for contacting Syncfusion support. 
  
In our PDF Viewer, there is no support to add form fields in the EJ1 control. We don't have any plan to implement this feature. We will fix only the bugs in our EJ1 control. In EJ2 control, we have planned the form designer implementation in our volume 2 release which is rolled out at the end of June. 

You can track the status using the below feedback link. 
  
  
Regards, 
Vasugi. 



IT Iván Torres replied to Vasugi Sivajothi June 24, 2021 12:25 PM UTC

Hi Vasugi,


I would need to know where a user has clicked (their coordinates for example) on a pdf page. I have found the PageClick event but I don't know if I could somehow know the position that the user has clicked.


Thanks in advance.



VS Vasugi Sivajothi Syncfusion Team June 25, 2021 11:57 AM UTC

Hi Ivan,  
  
Thank you for the update. 
  
We can get the X and Y position of the page using pageClick event. Please refer to the below code snippet and sample. 
  
Code Snippet: 
  
$("#pdfviewer").ejPdfViewer({ serviceUrl: 'https://js.syncfusion.com/ejServices/api/PdfViewer', pageClick:"pageClick"}); 
  
function pageClick(evt) { 
        console.log(evt); 
        console.log(evt.XCoordinate); 
        console.log(evt.YCoordinate); 
                             } 
  
  
  
Kindly try this and let us know if you have any concerns about this. 
  
Regards, 
Vasugi. 



IT Iván Torres July 1, 2021 11:25 AM UTC

Hi Vasugi,


Thank you very much, it was what I wanted.


Regards.



DM Dhivyabharathi Mohan Syncfusion Team July 2, 2021 10:44 AM UTC

Hi Ivan, 
  
Thank you for your update. We are glad to know that the reported issue is resolved. 
  
Regards, 
Dhivya. 


Loader.
Up arrow icon