findItemByText is undefined in typescript

i’ve wrote a function in js that enables/disables telerik RibbonBar’s elements.
when i tried to write it again in typescript, i’ve got an error on the call to the function ‘findItemByText’.

///enable / disable elements in the ribbonbar. example (true/false , "RadRibbonBar1", "");
function enableRibbonElement(enbaled_state_bool, ribbonbar_id, elements) {
    var rb = $find(ribbonbar_id);
    for (var i in elements)
        rb.  findItemByText  (elements[i]).set_enabled(enbaled_state_bool);
}


Source: javascript

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.