Hello, I need help.. I have a condition where when user hit add button toolbar on grid, it should prevent the modal to pop up when the condition didn't meet.
The partial view is not rendered, but there is still pop up like this
this is my code shown below
Thanks
and hey I need the modal pop up to become wizard modal, if you can show me how to pop up a modal costume template dialog on the toolbar click, so i can show wizard modal from another cshtml file.. im so lost, thanks
Hi Bernadus,
Greetings from Syncfusion support
Currently we are validating your query with your shared information, and we will update you the details on or before 26th July 2022. Until then we appreciate your patience.
Regards,
Rajapandi R
Hi Bernadus,
Thanks for your patience
We have checked your shared information and we could see that you like to prevent opening the dialog when the condition doesn’t meet, you can prevent opening the dialog by setting args.cancel as true. Please refer the below code example for more information.
|
<script> function begin(args) { //actionBegin event of Grid if (args.requestType === 'add') { if ('if the condition doesnt meet you can prevent the dialog') { args.cancel = true; //prevent open the dialog } else { //perform your action here } } } </script>
|
API: https://ej2.syncfusion.com/documentation/api/grid/#actionbegin
Regards,
Rajapandi R
thankyouu ill try it :)
Hi Bernadus,
Most welcome.
Regards,
Rajapandi R