JS函数在调试器中工作正常,但没有调试器就无法工作

时间:2015-04-08 07:03:51

标签: javascript

当我通过调试器执行它时,这个JavaScript函数工作正常,但是当我不使用调试器时,它没有执行:

function setColumnDisabled(){
    var activeGrid = null;
    var activeTab = tabbar1.getActiveTab();
    if (activeTab == "a1") {
        activeGrid = genInfo.mygrid;
    }else if (activeTab == "a2") {  
        activeGrid = genInfo.mygrid2;
    } else if (activeTab == "a21") {            
        activeGrid = genInfo.mygrid3;
    } else if (activeTab == "a22") {            
        activeGrid = genInfo.mygrid3;
    }else if(activeTab == "PartialTunnels"){
        activeGrid = genInfo.partialObjectsGrid;
    }
    if(activeGrid != null){
        activeGrid.forEachRow(function(row_id){
            activeGrid.cellById(row_id,activeGrid.getColIndexById("Shared")).setDisabled(true);
        });
    }
}

0 个答案:

没有答案