選択したサブグリッド行から特定のセル値を取得する必要があります。クリック イベントをサブグリッドにアタッチするコードを見つけましたが、行の名前または ID を取得します。セル値を取得する方法は?、私が訴えるコードは下 :
function ReadSelectedSubGridRecords() {
if (document.getElementById('Contacts')) {
var grid = document.getElementById('Contacts').control;
var ids = grid.get_selectedRecords();
for (var rowNo = 0; rowNo < grid.get_selectedRecords().length; rowNo++)
alert(grid.get_selectedRecords()[rowNo].Name);
}
}
function Form_OnLoad() {
if (document.getElementById('Contacts')) {
var grid = document.getElementById('Contacts');
if (grid.attachEvent) {
grid.attachEvent('onclick', ReadSelectedSubGridRecords);
}
}
else {
setTimeout("Form_OnLoad();", 2000);
}
}