js 如何获取treeview checkbox 选中的value的值 如题 我现在只能获取文本
function returnValue() {
var tree = document.getElementById("treeView").getElementsByTagName("INPUT");
for (var i = 0; i < tree.length; i++) {
if (tree[i].type == "checkbox" && tree[i].checked) {
// parent.document.getElementById()
window.opener.document.getElementById('TextBox_szbm').value = tree[i].nextSibling.firstChild.nodeValue;
window.close();
}
}
}
------解决方案--------------------------------------------------------
参见
http://dotnet.aspx.cc/file/Get-Selected-node-Text-and-Value-Of-ASPNET-Treeview-using-JavaScript.aspx