Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^2: Listbox keeping the selection in 1 listbox

by renegadex (Beadle)
on Jul 12, 2008 at 13:15 UTC ( [id://697208]=note: print w/replies, xml ) Need Help??


in reply to Re: Listbox keeping the selection in 1 listbox
in thread Listbox keeping the selection in 1 listbox

but how do i select that new item? i have tried to use $canvas->activate(1) but it doesn't highlight the item.. nothing seems to be working.. haaay...
  • Comment on Re^2: Listbox keeping the selection in 1 listbox

Replies are listed 'Best First'.
Re^3: Listbox keeping the selection in 1 listbox
by psini (Deacon) on Jul 13, 2008 at 09:30 UTC

    I never used Tk::Listbox so this is little more than a guess but, based on a cursory read of POD, I think that the methods you need are listbox->activate($index) that makes the element of index $index the current element and listbox->selectionSet($index,$index) that put the element $index in the selection set.

    Obviously you need to know the index of the element you want to activate, so you'll probably have to search for it in the listbox itself.

    Rule One: "Do not act incautiously when confronting a little bald wrinkly smiling man."

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://697208]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (8)
As of 2024-04-19 13:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found