多项选择脚本
<script LANGUAGE="javascript">
function SelectOK() { if (trim(document.Form1.Bjbh.value) == "" ) { alert("请先确定一个班级!"); document.Form1.Bjbh.focus(); return(false); } try{ var bjbhValue = ""; var bjbhName = ""; var bjbhList = document.all("Bjbh"); var bjbhListLen = bjbhList.options.length; for (i=1;i<=8;i++) { if(bjbhList.options(i).selected){ bjbhValue = bjbhValue + bjbhList.options(i).value + ","; bjbhName = bjbhName + bjbhList.options(i).text + ","; } } bjbhValue = bjbhValue.substr(0,bjbhValue.length-1); bjbhName = bjbhName.substr(0,bjbhName.length-1); //alert(trim(bjbhValue)); //alert(trim(bjbhName)); window.opener.window.document.all(document.Form1.UpdateBH.value).value = trim(bjbhValue); window.opener.window.document.all(document.Form1.UpdateXM.value).value = trim(bjbhName); window.close(); } catch(exception){ window.close(); } } </script> |
多项选择脚本
最新推荐文章于 2023-11-12 10:34:39 发布