in reply to Perl Tk Menus:Disabling and Re-enabling

Heys,

You need to use the menu->entryconfigure method, like this:

# $item is the item number in the menuitems array $menu -> menu -> entryconfigure($item, -state => "normal");

If you initially set the menu option to disabled, when you come to setting $consensus_created later in the code, you can use entryconfigure then to enable or disable (with -state => "disabled") the relevant menu options.

Hope that helps..
-- Foxcub

Update: Clarified things a little.

Replies are listed 'Best First'.
Re: Re: Perl Tk Menus:Disabling and Re-enabling
by Anonymous Monk on Dec 12, 2002 at 12:48 UTC
    Thanks guys,
    Foxcub's entryconfigure suggestion worked a treat :)

    basm101