RE: Win32::OLE-GetActiveObject not working!

2005-01-22 Thread Richard Grant

 Are you running XP SP2 or recently upgraded?

Yes to SP2, but not recent. Recent hot fixes.. auto applied by windows
update. Recently trying to use Win32::OLE though, so no help in finding out
if this is something new.. but others seem to have similar problems. This
returns the value zero:

use strict;
use Win32::OLE;
my $Count = Win32::OLE-EnumAllObjects;

 You may need to setup your DCOM permissions.

Checked that first, but what DCOM permissions, and how do I setup these
permissions so that perl.exe has sufficient rights when being run as me?
The default permissions are in place, and seem fairly permissive as reported
in dcomcnfg. In any case, I believe that the Computer defaults specify that
launch permission and activate permission go hand in hand.. no? Since I can
launch the application, why wouldn't I be able to activate the application?
And.. I am member of Administrator group.

 Your ID may not have rights to access the COM objects on your local PC.

I can use Internet Explorer and the Win32::OLE - Type Library Browser to
enumerate objects in Internet Explorer. I can use the Microsoft OLEView
application to enumerate and view objects. I can use mmc viewer to adjust
security settings of My Computer and individual DCOM items at an
administrative level.

 Under the Component Services mmc you can manage the permissions for
 your PC My computer, or you can manage individual objects.

Yup. Just in case, I added my specific username to the default permissions
at the Computer level with access to both local and remote rights in all
contexts. What is very odd is that Win32::OLE is unable to enumerate
objects, but it *is* allowed to launch them using the same interface.

 Start-run-dcomcnfg  (This will get you into the MMC.)

uh huh..

I'm still not certain that this behavior isn't just restricted to my machine
and a few other users. Is there a maintainer of the Win32::OLE core who can
set the record straight here?

Richard


 - Aaron Tesch

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of
 [EMAIL PROTECTED]
 Sent: Thursday, January 20, 2005 4:06 PM
 To: [EMAIL PROTECTED]; perl-win32-users@listserv.ActiveState.com
 Subject: RE: Win32::OLE-GetActiveObject not working!

 Richard,

 I've been having similar difficulty using Win32::OLE with Internet
 Explorer recently.  I wrote code that worked a month ago that doesn't
 work today.  Perl simply can't get an OLE connection to Internet
 Explorer anymore, even though I can still connect to Excel, etc.
 Something must have changed in Windows, but I haven't been able to find
 any related information on the net.

 Mike

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] Behalf Of
 Richard Grant
 Sent: Thursday, January 20, 2005 3:54 PM
 To: perl-win32-users@listserv.ActiveState.com
 Subject: RE: Win32::OLE-GetActiveObject not working!


  I could be wrong, but I don't think iTunes is an OLE Object which
 could
  be causing your troubles.

 Isn't OLE Automation just a layer on COM targeted toward scripting and
 VB in
 particular?

  It's a shame that it doesn't have a direct Perl API.

 Dunno, but I can do virtually everything with it using Win32::OLE, just
 this
 function seems to be acting odd. And it seems to be something that is
 part
 of a recent pattern that has root in the RPC layer.

 Richard

 ___
 Perl-Win32-Users mailing list
 Perl-Win32-Users@listserv.ActiveState.com
 To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
 
 **
 The information contained in this message, including attachments, may
 contain
 privileged or confidential information that is intended to be delivered
 only to the
 person identified above. If you are not the intended recipient, or the
 person
 responsible for delivering this message to the intended recipient,
 ALLTEL requests
 that you immediately notify the sender and asks that you do not read the
 message or its
 attachments, and that you delete them without copying or sending them to
 anyone else.


 ___
 Perl-Win32-Users mailing list
 Perl-Win32-Users@listserv.ActiveState.com
 To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs



___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Win32::OLE-GetActiveObject not working!

2005-01-21 Thread StoneBeat
I have the same problem with new MSN Messenger 

El Jueves 20 Enero 2005 23:05, [EMAIL PROTECTED] escribió:
 Richard,

 I've been having similar difficulty using Win32::OLE with Internet Explorer
 recently.  I wrote code that worked a month ago that doesn't work today. 
 Perl simply can't get an OLE connection to Internet Explorer anymore, even
 though I can still connect to Excel, etc.  Something must have changed in
 Windows, but I haven't been able to find any related information on the
 net.

 Mike

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] Behalf Of
 Richard Grant
 Sent: Thursday, January 20, 2005 3:54 PM
 To: perl-win32-users@listserv.ActiveState.com
 Subject: RE: Win32::OLE-GetActiveObject not working!

  I could be wrong, but I don't think iTunes is an OLE Object which could
  be causing your troubles.

 Isn't OLE Automation just a layer on COM targeted toward scripting and VB
 in particular?

  It's a shame that it doesn't have a direct Perl API.

 Dunno, but I can do virtually everything with it using Win32::OLE, just
 this function seems to be acting odd. And it seems to be something that is
 part of a recent pattern that has root in the RPC layer.

 Richard

 ___
 Perl-Win32-Users mailing list
 Perl-Win32-Users@listserv.ActiveState.com
 To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
 ***
*** The information contained in this message, including
 attachments, may contain privileged or confidential information that is
 intended to be delivered only to the person identified above. If you are
 not the intended recipient, or the person responsible for delivering this
 message to the intended recipient, ALLTEL requests that you immediately
 notify the sender and asks that you do not read the message or its
 attachments, and that you delete them without copying or sending them to
 anyone else.


 ___
 Perl-Win32-Users mailing list
 Perl-Win32-Users@listserv.ActiveState.com
 To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Win32::OLE-GetActiveObject not working!

2005-01-21 Thread Aaron.Tesch
Are you running XP SP2 or recently upgraded?

You may need to setup your DCOM permissions.

Your ID may not have rights to access the COM objects on your local PC.

Under the Component Services mmc you can manage the permissions for
your PC My computer, or you can manage individual objects.


Start-run-dcomcnfg  (This will get you into the MMC.)

- Aaron Tesch

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Thursday, January 20, 2005 4:06 PM
To: [EMAIL PROTECTED]; perl-win32-users@listserv.ActiveState.com
Subject: RE: Win32::OLE-GetActiveObject not working!

Richard,

I've been having similar difficulty using Win32::OLE with Internet
Explorer recently.  I wrote code that worked a month ago that doesn't
work today.  Perl simply can't get an OLE connection to Internet
Explorer anymore, even though I can still connect to Excel, etc.
Something must have changed in Windows, but I haven't been able to find
any related information on the net.

Mike

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of
Richard Grant
Sent: Thursday, January 20, 2005 3:54 PM
To: perl-win32-users@listserv.ActiveState.com
Subject: RE: Win32::OLE-GetActiveObject not working!


 I could be wrong, but I don't think iTunes is an OLE Object which
could
 be causing your troubles.

Isn't OLE Automation just a layer on COM targeted toward scripting and
VB in
particular?

 It's a shame that it doesn't have a direct Perl API.

Dunno, but I can do virtually everything with it using Win32::OLE, just
this
function seems to be acting odd. And it seems to be something that is
part
of a recent pattern that has root in the RPC layer.

Richard

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

**
The information contained in this message, including attachments, may
contain 
privileged or confidential information that is intended to be delivered
only to the 
person identified above. If you are not the intended recipient, or the
person 
responsible for delivering this message to the intended recipient,
ALLTEL requests 
that you immediately notify the sender and asks that you do not read the
message or its 
attachments, and that you delete them without copying or sending them to
anyone else. 


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Win32::OLE-GetActiveObject not working!

2005-01-20 Thread Michaud, Richard1
I could be wrong, but I don't think iTunes is an OLE Object which could
be causing your troubles.

It's a shame that it doesn't have a direct Perl API.

Richard Michaud

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Richard Grant
Sent: Thursday, January 20, 2005 3:30 PM
To: perl-win32-users@listserv.ActiveState.com
Subject: Win32::OLE-GetActiveObject not working!

Here is a snippit based on the example in the ActivePerl User Guide with
iTunes instead of Excel..

# use existing instance if iTunes is already running
eval {$iTunesHandle =
Win32::OLE-GetActiveObject('iTunes.Application')};
die iTunes not installed if $@;
unless (defined $iTunesHandle) {
  $iTunesHandle = Win32::OLE-new('iTunes.Application', sub
{$_[0]-Quit;})
 or die Oops, cannot start iTunes;
}

A running instance of iTunes will always be killed, because
Win32::OLE-GetActiveObject never finds an object! I tried a generic
CLSID, and specific PROGID version strings, but nothing makes
GetACtiveObject return an object. I used OLEView to check on the CLSID
of iTunes.. you can see it is just a fairly straightforward interface.

I think this is a problem with RPC, SP2 and new security patches. I had
some other trouble with RPC recently for an install program for a USB
DSL modem.. it died at the end with an RPC call failed message. No one
seemed to know what I was talking about (happened 2 days ago), but I'm
certain my computer is ok. I was going to use Safe Mode boot to play
with the permissions, but I can't afford the time to reinstall windows
if something goes wrong.

Any other applications that can't use GetActiveObject through a typelib
interface? Is there a work around for this? Is it just my problem?

Richard


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Win32::OLE-GetActiveObject not working!

2005-01-20 Thread Richard Grant
 I could be wrong, but I don't think iTunes is an OLE Object which could
 be causing your troubles.

Isn't OLE Automation just a layer on COM targeted toward scripting and VB in
particular?

 It's a shame that it doesn't have a direct Perl API.

Dunno, but I can do virtually everything with it using Win32::OLE, just this
function seems to be acting odd. And it seems to be something that is part
of a recent pattern that has root in the RPC layer.

Richard

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Win32::OLE-GetActiveObject not working!

2005-01-20 Thread Mike.Owens
Richard,

I've been having similar difficulty using Win32::OLE with Internet Explorer 
recently.  I wrote code that worked a month ago that doesn't work today.  Perl 
simply can't get an OLE connection to Internet Explorer anymore, even though I 
can still connect to Excel, etc.  Something must have changed in Windows, but I 
haven't been able to find any related information on the net.

Mike

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of
Richard Grant
Sent: Thursday, January 20, 2005 3:54 PM
To: perl-win32-users@listserv.ActiveState.com
Subject: RE: Win32::OLE-GetActiveObject not working!


 I could be wrong, but I don't think iTunes is an OLE Object which could
 be causing your troubles.

Isn't OLE Automation just a layer on COM targeted toward scripting and VB in
particular?

 It's a shame that it doesn't have a direct Perl API.

Dunno, but I can do virtually everything with it using Win32::OLE, just this
function seems to be acting odd. And it seems to be something that is part
of a recent pattern that has root in the RPC layer.

Richard

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
**
The information contained in this message, including attachments, may contain 
privileged or confidential information that is intended to be delivered only to 
the 
person identified above. If you are not the intended recipient, or the person 
responsible for delivering this message to the intended recipient, ALLTEL 
requests 
that you immediately notify the sender and asks that you do not read the 
message or its 
attachments, and that you delete them without copying or sending them to anyone 
else. 


___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs