Check documentation for the latest version of dhtmlxSuite Using Iterator DHTMLX Docs

Using Iterator

The method forEachWindow() calls a user-defined function for every existing window passing a window handler into it. For example, you can use the method setText() to sets windows' header text.

myWins.forEachWindow(function(win){     // calling iterator
    myWins.setText(text);               // your code here, for example, setText()
});
 
// or
function doWithWindow(win){
    myWins.setText(text);               // your code here, for example, setText()
});
myWins.forEachWindow(doWithWindow);     // calling iterator

Related sample:  Iterator

Back to top