What do you mean by "in background"?
If you wish to perform some tasks "in background" while user sees login
window, enters his login/pass, etc - I think the only way is to create a
multithreaded application.
But if you just want to create/show window and then perform some extra
code, you can call Win32::GUI::DoEvent instead of Win32::GUI::Dialog().
It will draw the window and all stuff but won't "stop" for interaction
with user. Of course you should call Win32::GUI::Dialog() at some point
to allow user to interact with your application.
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Brian Rowlands (Greymouth High School)
Sent: Wednesday, April 23, 2008 4:06 PM
To: perl-win32-gui-users@lists.sourceforge.net
Subject: [perl-win32-gui-users] Window doesn't appear until code has
finished
I'm writing a login gui in perl and I've got a mental block:
I've created my gui:
my $main = Win32::GUI::Window->new(
-name => 'Main',
-width => 600,
-height => 400,
-text => 'GHS Login',
-sizable=> 0,
-hasminimize => 0,
-hasmaximize=> 0,
);
... widgets positioned
$main->Center();
$main->Show();
Win32::GUI::Dialog();
exit(0);
My question is, how can I get the window to be displayed and then have
perl code running in the background?
I've tried:
sub Main_Activate {
... perl code
return 0;
}
The perl code runs and then the window appears.
Thanks
Brian Rowlands
We must accept finite disappointment, but we must never lose infinite
hope.
Martin Luther King Jr. <file:///\\quotes\k\martinlutherking\>
=======================================================
Ce message et toutes les pieces jointes (ci-apres le "message")
sont confidentiels et etablis a l'intention exclusive de ses destinataires.
Toute utilisation ou diffusion non autorisee est interdite.
Tout message electronique est susceptible d'alteration.
La SOCIETE GENERALE et ses filiales declinent toute responsabilite
au titre de ce message s'il a ete altere, deforme ou falsifie.
=======================================================
This message and any attachments (the "message") are confidential
and intended solely for the addressees.
Any unauthorized use or dissemination is prohibited.
E-mails are susceptible to alteration.
Neither SOCIETE GENERALE nor any of its subsidiaries or affiliates
shall be liable for the message if altered, changed or falsified.
=======================================================
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Perl-Win32-GUI-Users mailing list
Perl-Win32-GUI-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users
http://perl-win32-gui.sourceforge.net/