I'm trying to experiment with Win32::GUI using ActiveState Perl 5.8.4 (build 810) under Windows 98. I'm trying to follow the examples in the Win32::GUI tutorial, but the first example in the tutorial is failing.

use Win32::GUI; use strict; use warnings; my $main = Win32::GUI::Window->new(-name => "Main", -width => 110, -he +ight => 100); # This line is failing $main->AddLabel(-text => "Hello, world"); $main->Show(); Win32::GUI::Dialog(); exit; # terminate the message loop when the window is closed sub Main_Terminate { -1 }

The AddLabel line is causing an illegal operation error with the following message:

PERL caused an invalid page fault in
module MSVCRT.DLL at 0167:78002fc5.

I installed Win32::GUI using the PPM system. If I removed the AddLabel line, the script runs and displays the empty window.

Has any one else experienced a problem like this? Is this a known problem, with a known work-around? Does Win32::GUI just not work under Windows 98? Thanks for any help you can provide.


In reply to Invalid Page Fault With Win32::GUI Under Win98 by Belgarion

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.