COM
Syntax: #COM comvariable methodname [arguments]
Executes a method for a COM object. Create a comvariable reference using %comcreate. If the method requires any arguments, list them after the method name. Method names in COM are CASE SENSITIVE.
See #CALL for an alternative syntax
Examples:
#VAR NameSpace %comget(Outlook,
"GetNamespace", "MAPI")
#VAR Folders %comget(NameSpace, "Folders", "InBox")
#VAR InBox %comget(Folders, "Folders", "InBox")
#VAR Msg %comget(InBox,"Items",1)
#COM Msg Save
Retrieves the first email message in your InBox (stored in Msg). Then changes the Subject property of that message to "This is a test". Then, using the #COM command, the new message is saved.
#VAR NameSpace @Outlook.GetNamespace("MAPI")
#VAR Folders @NameSpace.Folders("InBox")
#VAR InBox @Folders.Folders("InBox")
#VAR Msg @InBox.Items(1)
#CALL @Msg.Save
Alternate syntax for the same result. Uses the short-cut syntax for accessing COM methods and properties, and uses the #CALL command instead of the #COM command to execute function calls.