|
From: Robert M. <ro...@th...> - 2009-03-04 17:16:57
|
2009/3/4 Mike Carambat <mc...@ro...>:
> So far, I can get the handle on the window and even issue a CloseWindow, so I know I’m hooked into it, but I
> am having trouble with sending the commands over WM_COPYDATA.
As you don't have warnings turned on, and you're using cgi, you can't
see the warnings/errors that perl is helpfully giving you:
C:\>perl -MWin32::GUI -e "print WM_COPYDATA();"
Undefined subroutine &main::WM_COPYDATA called at -e line 1.
C:\>perl -w -MWin32::GUI -e "print WM_COPYDATA();"
'use Win32::GUI;' is currently exporting constants into the callers scope. This
functionality is deprecated. Use 'use Win32::GUI();' or list your required expor
ts explicitly instead. at -e line 0
Undefined subroutine &main::WM_COPYDATA called at -e line 1.
C:\>perl -w -MWin32::GUI=WM_COPYDATA -e "print WM_COPYDATA();"
74
> #!/usr/bin/perl
> # WinLiRC Perl interface
>
> chdir ("cgi-bin");
>
> use Win32::GUI;
Try changing this line to:
use Win32::GUI qw(WM_COPYDATA);
Win32::GUI only exports a rather small subset of the constants by
default (the original exports are maintained for backward
compatibility purposes). Generally you want to list the constants you
require access to on the 'use Win32::GUI' line. See
Win32::GUI::Constants and the release notes for further information.
[I haven't checked that the rest of the script works, but it looks OK
at a first glance].
Hope that helps.
Rob.
|