<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.2.2">
</HEAD>
<BODY>
New to PerlQt. Long time expert with Qt C++. So-so with Perl, and very to to Object Perl.<BR>
<BR>
I am trying to make a form pop up when a button is clicked. I have tried dozens of combinations but cannot get this to work. I get different errors that I think are caused by the variable for the sub form object. <BR>
<BR>
Where can I put the $SubForm1 variable? Does Object Perl have any way to define a member variable that is global only to the parent object?<BR>
<BR>
<BR>
package MainForm;<BR>
use Qt;<BR>
use MainFormGUI;<BR>
use Qt::isa "MainFormGUI";<BR>
use SubForm;<BR>
use Qt::slots<BR>
OnButtonPress => [];<BR>
<BR>
$SubForm1 = SubForm;<BR>
<BR>
sub NEW<BR>
{<BR>
my $self = shift;<BR>
$self->SUPER::NEW(@_);<BR>
setCaption("Tester");<BR>
this->connect(pushButton1, SIGNAL('clicked()'), SLOT('OnInstall()'));<BR>
pushButton1->setFocus();<BR>
}<BR>
<BR>
sub OnButtonPress<BR>
{<BR>
print "OnButtonPress\n";<BR>
hide();<BR>
if(radioButton1->isChecked() == 1)<BR>
{<BR>
$SubForm1->show();<BR>
}<BR>
}<BR>
<BR>
<BR>
<BR>
<TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
<BR>
<TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
<U><A HREF="mailto:roy@SiliconTao.com">Roy Souther</A></U><BR>
<U><A HREF="http://www.SiliconTao.com">www.SiliconTao.com</A></U><BR>
Let Open Source help your business move beyond.<BR>
<BR>
For security this message is digitally authenticated by <U><A HREF="http://www.gnupg.org">GnuPG</A></U>.
</TD>
</TR>
</TABLE>
<BR>
<BR>
<BR>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>