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
close icon

New Workbook Event Handler

Hi there!

is there any way to fire a callback when creating a new workbook, e.g. when we click on the `New` button from top left menu


Thank you in advance
Best


4 Replies

SP Sangeetha Priya Murugan Syncfusion Team October 7, 2022 10:19 AM UTC

Hi Reda,


Your requirement can be achievable by using the fileMenuItemSelect event as like as below.


CODE BLOCK:


 

 

 function fileMenuItemSelect(args) {

    console.log(args.item.text); // returns the selected item text

  }


Sample Link: https://stackblitz.com/edit/react-xg7zxr?file=index.js


API Link: https://ej2.syncfusion.com/react/documentation/api/spreadsheet/#filemenuitemselect


Kindly get back to us if you need further assistance regarding.


Regards,

Sangeetha M                   



RE Reda El Khayat October 7, 2022 10:24 AM UTC

Thank you Sangeetha for the reply
I'm not sure this will work as the new worksheet needs a confirmation (basically, when we click on "New" it opens a modal to confirm new workbook creation) - what I need to do is to know if user choose to proceed to not 


Best



SP Sangeetha Priya Murugan Syncfusion Team October 10, 2022 12:48 PM UTC

Hi Reda,


Currently, we don’t have any event for creating the new workbook in spreadsheet. And we need to check the feasibility of this requirement. So, we will update you the further details on October 12th, 2022. We appreciate your patience until then.


Regards,

Sangeetha M



SP Sangeetha Priya Murugan Syncfusion Team October 11, 2022 02:23 PM UTC

Hi Reda,


Before we proceed further, please share your requirement for call back event while creating new workbook. Is there any customization need to be done in your side? If yes, please share the detailed description of your requirement based on that we will check and provide you a better solution quickly.


Regards.

Sangeetha M


Loader.
Live Chat Icon For mobile
Up arrow icon