• help on progressbar

    From xavier.hervieu@gmail.com@21:1/5 to All on Mon May 30 07:21:07 2016
    Le mardi 10 novembre 2009 15:57:58 UTC+1, aroul a écrit :
    Hi,


    I am trying to learn perl tk. Any help to find the error in this code
    greatly appreciated.

    Running this code generates below error -


    Can't call method "g_start" without a package or object reference at progressbar.pl line 17.



    #!/Perl/bin/perl -w

    use strict;

    use Tkx;

    my $mw = Tkx::widget->new(".");
    $mw->g_wm_title ("Title");
    $mw->g_wm_geometry ("500x200+500+250");

    my $progress = $mw->new_ttk__frame (-padding => "3 3 3 3", -relief => "flat");
    $progress->g_grid (-column => 0, -row => 1, -sticky => "nwes");


    my $pbar = $progress->new_ttk__progressbar (-orient => "horizontal", -
    length => 200, -mode => "indeterminate")->g_grid (-column => 0, -row
    0, -sticky => "w");

    $pbar->g_start();


    #$pbar->g_stop();

    Tkx::MainLoop()


    regards
    aroul.

    Hello,
    if still searching, change your "g_start" and "g_stop" to "m_start" and "m_stop". i try and it works but a "Tkx::Update;" is needed to see the changes.
    regards
    Xavier

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)