Protocols/MSNP/Activities/SDK/Techref/Objectmodel/Objects/Channel/Events/OnIMReceived: Difference between revisions
Jump to navigation
Jump to search
Animadoria (talk | contribs) (Created automatically by Anima Importer) |
Animadoria (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
<!-- Generated @ 08/12/2022 23:45:54 +01:00 using Anima's CHM converter based on techref/objectmodel/objects/channel/events/OnIMReceived.htm --> | <!-- Generated @ 08/12/2022 23:45:54 +01:00 using Anima's CHM converter based on techref/objectmodel/objects/channel/events/OnIMReceived.htm --> | ||
{{Protocols/MSNP|section=Activities}} | {{Protocols/MSNP|section=Activities}} | ||
__NOTOC__= | __NOTOC__= = [[Protocols/MSNP/Activities/SDK/Techref/Objectmodel/Objects/Channel/Index|Channel]].OnIMReceived Event (Restricted) = | ||
This event fires when an instant message is received from the remote application. The event is labeled "restricted" because it is only available if the application has either the ReplaceIM or ReceiveIM permission flag. For more information, see [[Protocols/MSNP/Activities/SDK/Sandbox|Standard vs. Advanced Applications]]. | This event fires when an instant message is received from the remote application. The event is labeled "restricted" because it is only available if the application has either the ReplaceIM or ReceiveIM permission flag. For more information, see [[Protocols/MSNP/Activities/SDK/Sandbox|Standard vs. Advanced Applications]]. | ||
VBScript Syntax | === VBScript Syntax === | ||
<div class="clsCodeStd"> | <div class="clsCodeStd"> | ||
Line 17: | Line 17: | ||
</div> | </div> | ||
JavaScript Syntax | === JavaScript Syntax === | ||
<div class="clsCodeStd"> | <div class="clsCodeStd"> | ||
Line 28: | Line 28: | ||
</div> | </div> | ||
Remarks | === Remarks === | ||
If an application has the ReceiveIM permission flag, it can inspect the value of Channel.IM. With the ReplaceIM permission flag, it can inspect and modify the value of Channel.IM. If an application has neither permission flag, the <span class="clsEvent">OnIMReceived</span> event will not fire, and Channel.IM will remain empty. | If an application has the ReceiveIM permission flag, it can inspect the value of Channel.IM. With the ReplaceIM permission flag, it can inspect and modify the value of Channel.IM. If an application has neither permission flag, the <span class="clsEvent">OnIMReceived</span> event will not fire, and Channel.IM will remain empty. | ||
Changes must be made to Channel.IM before the <span class="clsEvent">OnIMReceived</span> event is finished for the changes to be displayed in the Chat History. | Changes must be made to Channel.IM before the <span class="clsEvent">OnIMReceived</span> event is finished for the changes to be displayed in the Chat History. |
Revision as of 00:51, 13 August 2022
= Channel.OnIMReceived Event (Restricted)
This event fires when an instant message is received from the remote application. The event is labeled "restricted" because it is only available if the application has either the ReplaceIM or ReceiveIM permission flag. For more information, see Standard vs. Advanced Applications.
VBScript Syntax
function Channel_OnIMReceived() ' Instant message was received, inspect the value of Channel.IM ' If ReplaceIM permission, Channel.IM can be written to before it is displayed. End Function
JavaScript Syntax
function Channel_OnDataReceived() { // Instant message was received; inspect the value of Channel.IM // If application has ReplaceIM permission, Channel.IM can be written to before it is displayed. }
Remarks
If an application has the ReceiveIM permission flag, it can inspect the value of Channel.IM. With the ReplaceIM permission flag, it can inspect and modify the value of Channel.IM. If an application has neither permission flag, the OnIMReceived event will not fire, and Channel.IM will remain empty.
Changes must be made to Channel.IM before the OnIMReceived event is finished for the changes to be displayed in the Chat History.