Hello,
I'm making a custom dialog component
following the prompt demo that's in:
https://ej2.syncfusion.com/16.1.32/angular/demos/#/material/dialog/basic.
I need to call two different methods
in sequence when I click on the “Confirm” button from the dialog
window. Both of these methods are defined in the parent app. The
first method runs without problems when it's directely called by the
button object's click event, but the second one get's an error saying
that that method isn't a function when it is. The second one is
called right after the first method is done.
Fusing both methods didn't work because
the second one needs information that's stored in a varaible from the
parent app. When I tried to run that single method I got an error
saying that the variable that I was calling is 'undefined'.
It's like the dialog prompt can't see
the parent app's methods and variables besides the ones that are
linked to the buttons events.
My question is, does the dialog
component have an equivalent method to “window.opener.foo()”
that's present in javascript? I tried doing “this.opener.foo()”
inside the method that works but that didn't work either.
Thanks for the help!