The Win32::API::Struct v0.41 module documentation states the following:
Also note that typedef automatically defines an 'LPNAME' type, which holds a pointer to your structure.
Using the example in that documentation, I have created a POINT structure. This should mean that I have also automatically created an LPPOINT structure.
If this is the case, why does the following not work:
#!c:\perl\bin\perl -w use strict; use Data::Dumper; use Win32::API; Win32::API::Struct->typedef( 'POINT', 'LONG', 'x', 'LONG', 'y' ); my $point = Win32::API::Struct->new( 'LPPOINT' ) or die $!; print Dumper( $point );
with the error message being:
Unknown Win32::API::Struct 'LPPOINT' at C:\point.pl line 9 Died at C:\point.pl line 9, <DATA> line 164.
Is the documentation wrong or am I not reading it correctly?
Thanks,
fx, Infinity is Colourless
In reply to Win32::API::Struct - Automatic pointer creation not working ? by fx
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |