Loading ...
Sorry, an error occurred while loading the content.
 

Perl/Tk

Expand Messages
  • GARCIA Lionel
    Hi, It seems I have a little problem passing arguments: Here s the code: sub foo { my ($machine)=@_; print $machine; } $lb_liste- bind( , [ &foo,
    Message 1 of 4 , Sep 3, 2001
      Hi,
      It seems I have a little problem passing arguments:
      Here's the code:

      sub foo
      {
      my ($machine)=@_;

      print \$machine;
      }

      $lb_liste->bind('<Button-1>', [ \&foo,
      $lb_liste->get($lb_liste->curselection()) ]);

      And here is the error:
      wrong # args: should be ".frame.listbox get first ?last?" at
      /usr/perl5/site_perl/5.005/sun4-solaris/Tk.pm line 217.
      But if I use the following line:
      #$lb_liste->bind('<Button-1>', sub { print
      $lb_liste->get($lb_liste->curselection()) });
      it works fine and print the correct entry (a string).

      So, where am I wrong ?


      Lionel GARCIA
      Cap Gemini Ernst&Young - Support stations Unix
      * : lionel.garcia@...
    • Matt Giddings
      Hello, Is there a group for perl/tk? I ve looked on groups.yahoo.com and did not turn up anything. Thanks, Matt
      Message 2 of 4 , Apr 15 12:04 PM
        Hello,

        Is there a group for perl/tk? I've looked on groups.yahoo.com and
        did not turn up anything.

        Thanks,
        Matt
      • Jonathan E. Paton
        ... Probably. ... Look in another place, which is: lists.perl.org there you can also subscribe to the higher volume beginners@perl.org mailing list - just
        Message 3 of 4 , Apr 15 1:35 PM
          > Is there a group for perl/tk?

          Probably.

          > I've looked on groups.yahoo.com and did not turn up anything.

          Look in another place, which is:

          lists.perl.org

          there you can also subscribe to the higher volume
          beginners@... mailing list - just don't cross post. That
          page lists all the important mailing lists.

          Jonathan Paton

          __________________________________________________
          Do You Yahoo!?
          Everything you'll ever need on one web page
          from News and Sport to Email and Music Charts
          http://uk.my.yahoo.com
        • Matt Giddings
          ... Cool! ... Yup, I d say there are a few perl lists there. Thanks for pointing me in the right direction. Matt
          Message 4 of 4 , Apr 15 1:43 PM
            On Mon, 15 Apr 2002, Jonathan E. Paton wrote:

            > > Is there a group for perl/tk?
            >
            > Probably.


            Cool!

            >
            > > I've looked on groups.yahoo.com and did not turn up anything.
            >
            > Look in another place, which is:
            >
            > lists.perl.org


            Yup, I'd say there are a few perl lists there. Thanks for pointing me
            in the right direction.

            Matt
          Your message has been successfully submitted and would be delivered to recipients shortly.