use strict;
use Tk;
my $i = 0;
my $labeltext = '';
my $mw = MainWindow->new(-title=>'Labeltest');
$mw->minsize(500,200);
$mw->Label(-textvariable=>\$labeltext,-background=>'red')->pack(-fill=>'both');
$mw->Button(-text=>'Verändere Text',-command=>\&veraendere_text)->pack();
$mw->Button(-text=>'Quit',-command=>sub{$mw->destroy();})->pack();
MainLoop;
sub veraendere_text () {
my @text = qw/Labeltext1 Labeltext2 Text3 etc/;
$labeltext = @text[$i];
$i = 0 if $i++ >= 3;
}