> [EMAIL PROTECTED] - Tue Nov 13 00:33:50 2001]:
>
>
> > Now again: Can you produce a *working* *subset* of your current script
> > that reproduces the error you had been mentioning?
>
> After a lot of fiddling, I have determined that the cause of the error was
> something completely unrelated to what I first thought it was.
Enclosed is
> a small script that illustrates the problem;
>
> #!/usr/bin/perl
> use strict;
> use warnings;
> use Win32::Console;
>
> my $thing = Test();
> printf "Return is : $thing\n"; # This never gets printed...
>
> sub Test
> {
> my $OUT = new Win32::Console(STD_OUTPUT_HANDLE);
> $OUT->Cls();
> $OUT->WriteChar("Press a key",1,2);
> <STDIN>;
> return 2;
> }
>
> Basically, it seems that if a new console object is created in a
subroutine,
> once the subroutine is exited, it is no longer possible to print to the
> screen. I have tried using $OUT->Free() at the end of the sub before
> returning, but that seems to make no difference.
> I've discovered that program execution continues just fine (I can write to
> an output filehandle, for example), but there's no screen output.
>
> Any pointers would be appreciated.
>
> Thanks,
>
> Andrew
>
Sorry, but Win32::Console is not part of the core Perl distribution. It
is part of the core ActiveState distribution, so you can report the bug
to them at http://bugs.activestate.com//ActivePerl/query.cgi.