Set disable menu commands

  1. #1

    Set disable menu commands

    I have a GridCommand and i can't disable a Menu command.
    I try:

    
    
    
    GridPanel.colModel.columns[9].commands[0].menu.items[0].disabled = false;
    
    
    GridPanel.colModel.columns[9].commands[0].menu.items[1].disabled = true;
    
    
    GridPanel.colModel.columns[9].commands[0].menu.items[2].disabled = true;
    
    
    GridPanel.colModel.columns[9].commands[0].menu.items[3].disabled = false;
    for each menu command but all remain enable. It's possible disable its according to criteria?
    Thanks.






  2. #2

    RE: Set disable menu commands

    Hi,

    GridPanel1.colModel.columns[5].commands[0].disabled = true;
    GridPanel1.view.refresh();
  3. #3

    RE: Set disable menu commands





    
    
    
    GridPanel.colModel.columns[9].commands[0].menu.items[0].disabled = true;
    
    
    
    GridPanel.view.refresh() ;
    
    GridPanel.view.refresh() is undefined.

    And the menu is not deployed. I have some Icons in the menu and i want to make disable only one ot them. I don't want to disable all the column. There is another way to do it?

    Thanks

Similar Threads

  1. [CLOSED] How to disable whole CycleButton with menu by javascript?
    By leon_tang in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: May 17, 2012, 12:28 PM
  2. [CLOSED] Disable Treegrid column menu
    By Pablo_Azevedo in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Apr 27, 2012, 7:31 PM
  3. Replies: 2
    Last Post: Feb 22, 2012, 4:16 PM
  4. Styling Grid Commands
    By Summ0ner in forum 1.x Help
    Replies: 1
    Last Post: Feb 02, 2010, 2:40 PM
  5. How to disable the browser's right click menu?
    By dbassett74 in forum 1.x Help
    Replies: 1
    Last Post: Apr 23, 2009, 8:26 PM

Posting Permissions