Grid Toolbar Dialog target

Hello,

I need modify properties of dialog created from grid toolbar. I need to change the target of that dialog to be "body" so the overlay covers the whole page (please see https://i.imgur.com/m1H1b4Y.png). Is there any chance to do that programmatically?

Thank you,
Jiri Blazek

3 Replies 1 reply marked as answer

TS Thiyagu Subramani Syncfusion Team February 10, 2021 12:34 AM UTC

Hi Jirí, 

Thanks for contacting Syncfusion support. 

To achieve your requirement we suggest you to define the dialog’s target as body in beforeOpen event.  Please refer to the below code and sample link. 

 load(args) { 
    (this.grid.editModule as any).alertDObj.beforeOpen = function(args: any) { 
      this.target = document.getElementsByTagName("body")[0]; 
      this.dataBind(); 
    }; 
  } 




Please get back to us, if you need any further assistance. 

Regards, 
Thiyagu S 


Marked as answer

JB Jirí Blažek February 10, 2021 11:33 AM UTC

Hi Thiyagu,

thank you, that solved the problem.

Jiri


TS Thiyagu Subramani Syncfusion Team February 11, 2021 06:20 AM UTC

Hi Jirí, 

Thanks for your update. 

We are happy to hear that the provided solution works at your end. 

Please get back to us, if you need any further assistance. 

Regards, 
Thiyagu S 


Loader.
Up arrow icon