I tried some time ago to get a .pls perlscript to work with Window-Eyes. It seems that I can only get parts of it to work. I can use the speech.speak method to make it talk, but I can't seem to use the ClientInformation object and I can't get the Keyboard->RegisterHotkey method to work either. I'll paste in the script fragments I have below my message here. Note that this just a script to play around and see if I can get basic perl support to work as another language for WE scripts. Also, when it identifies the window-Eyes name and version, those properties get spoken; I just can't seem to do anything with ClientInformation.

When I try to use the ClientInformation object, I keep getting an error about referencing a hash without a valid reference or such.
----- Begin ----- hello.pls
use Win32;
use Win32::OLE;
my $we = Win32::OLE->new("WindowEyes.Application");

#$we->ClientInformation->ScriptDescription ("Test Perl script");
my $version = $we->{'Version'};
#my $path = $we->ClientInformation->{'ScriptPath'};
my $file = $we->{'Name'};
#my $path = "c:/html/";c:
$we->Speech->Speak($path);
#hello();
my $registeredKey = $we->Keyboard->RegisterHotkey("Alt-G", "hello()");

sub hello {
$we->Speech->Speak("Hello World from $we-ClientInformation->{'ScriptFileName'}!"); Win32::MsgBox("Callback routine was successfully called from Window-Eyes Version $version\nrunning $file", 1, "Callback");
----- End hello.pls -----
Any ideas out there?
}

Reply via email to