var list = scene.getBoxById("myList"); if (list) { var sel = list.selection; if (sel) { shell.print("Number of rows currently selected is: " + sel.rowCount); } }