ParentAppWindow class
An object that is utilized to facilitate communication with a parent window that initiated the opening of current window. For instance, a dialog or task module would utilize it to transmit messages to the application that launched it.
Properties
Instance | Get the parent window instance. |
Methods
add |
Add a listener that will be called when an event is received from the ParentAppWindow. |
post |
Send a message to the ParentAppWindow. |
Property Details
Instance
Method Details
addEventListener(string, addEventListnerFunctionType)
Add a listener that will be called when an event is received from the ParentAppWindow.
function addEventListener(type: string, listener: addEventListnerFunctionType)
Parameters
- type
-
string
The event to listen to. Currently the only supported type is 'message'.
- listener
- addEventListnerFunctionType
The listener that will be called
postMessage(any, onCompleteFunctionType)
Send a message to the ParentAppWindow.
function postMessage(message: any, onComplete?: onCompleteFunctionType)
Parameters
- message
-
any
The message to send
- onComplete
- onCompleteFunctionType
The callback to know if the postMessage has been success/failed.
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈