Name
GetActiveObject
Synopsis
Win32::OLE->GetActiveObject( progid )
Description
Creates an object for a currently active instance of a server, if one
exists. If the server is registered, but no instance of it is running, the
method returns undef
. If the server is not registered, the method
will croak
.
You should probably call GetActiveObject
inside an eval
so that you can do exception handling in the event that the
server is unregistered or is not currently running. If the method
returns undef
, you can just create a new instance of the server
and the object with new
.
Get Perl in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.