On Wednesday, June 25, 2003, at 08:27 AM, Yvon Thoraval wrote:

my $okHTML = $self->{'myCB'}->stringValue;

Perl error: Can't call method "stringValue" without a package or object reference

The outlet $self->{'myCB'} is not being connected to the check box. That is because - as it says in the docs - the first letter of an outlet's name must be capitalized.


$self->{'myCB'} = 0 or 1

and reading it afterwards, gives the correct 0 or 1 without the check box being checked...

That simply re-assigns the variable - naturally, it has no effect on the check box the variable used to refer to.


To change the status of a check box, use the setState() method, like this:

$self->{'MyCB'}->setState(1); # or 0, to turn it off

sherm--

A well-written program is its own heaven; a poorly-written program is its own hell.

-- The Tao of Programming

Reply via email to