Dialog Form width

Hello,
I Know that with templates it is possible to have full control over the HTML of the dialog form, but I want to simply use a simple mode="Dialog" for the grid and have the popup to a reasonable width, is it possible to do this without any further coding just from the Grid properties itself? the default popup is really too small. Thanks in advance.

3 Replies 1 reply marked as answer

VS Vignesh Sivagnanam Syncfusion Team March 8, 2021 10:47 AM UTC

Hi Yoab 

Greetings from Syncfusion support. 

Based on your query you need to increase the width of the edit dialog popup in the grid with default grid properties.  

By default in EJ2 Grid edit dialog mode we render the EJ2 Dialog in the source level, so it is not possible to increase the size of the dialog popup with default grid properties. To achieve your requirement, we suggest to use the EJ2 grid actionComplete event.  

The actionComplete event is triggered you can able to acquire the EJ2 Dialog instance in the arguments. Using dialog instance you can able to modify the width of the edit dialog popup. Please refer the below code example and sample 

Code example: 
<script> 
  function actionComplete(args) { 
    if (args.requestType === "beginEdit") { 
      args.dialog.width = "700px"; 
    } 
  } 
</script> 


Regards 
Vignesh Sivagnanam 


Marked as answer

YY Yoab Youssoufou March 8, 2021 11:18 AM UTC

Hi Vignesh,
It's perfect. thank you.


SK Sujith Kumar Rajkumar Syncfusion Team March 9, 2021 04:42 AM UTC

Hi Yoab, 
 
We are glad to hear that the provided solution helped resolve your query. 
 
Please get back to us if you require any further assistance. 
 
Regards, 
Sujith R 


Loader.
Up arrow icon