I can't seem to pass $count into the command to use as an identifier for this particular widget because it will change as $counter changes with time. I'm looking for a way to be able to identify which button was pressed. I've been trying to do it using x and y coordinates, but it has to be in a scrolling pane and it keeps screwing up my logic when the pane scrolls down. I'm relatively new to perl and Tk and I'm aware that using variables to define variables is poor practise at best. Thanks,sub makewidget{ $counter=shift; ${widget."$counter"}=$mw->Button( -command=>sub{configurewidget($counter)} )->pack(); }
In reply to Widget Information by Commy_Code_Monkey
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |