|
Contents | Previous | Next | Subchapters |
| Syntax |
coinvoke(method name)method name, method arguments) |
| See Also | cocreate , copropget |
cowith and coendwith functions
for an explanation of navigating object model hierarchies.
If present, method arguments may be integer, real,
or double precision matrices, logical scalars, or character row
vectors. The values of method arguments are passed
to method name.
If the specified method name does not return
a result, the result of coinvoke will be
the O-Matrix constant novalue. If method name
does return a result, the value created by coinvoke
will be an integer, real, or double precision matrix, a logical
scalar, or character row vector.
clear
cocreate("Excel.Application")
coinvoke("CentimetersToPoints", 5.5)
coinvoke("Quit")
O-Matrix will respond
155.906
clear
cocreate("Excel.Application")
fileName = coinvoke("GetSaveAsFileName")
Excel will post a dialog for entering a file name and
after pressing OK your input result will be saved to the
O-Matrix variable, fileName. If you continue
the example by entering
print fileName
O-Matrix will echo the name of the file that you entered in
the dialog.
coinvoke("Quit") in the example above
does not return a result.