我想实现如下的功能:数据输入表单里,点击一个按钮,弹出一个数据选择窗口,然后选择某一数据后,将值返回到数据输入表单.
谁有没有这样的封装好了的控件或代码?

解决方案 »

  1.   

    主窗口中弹出一个模式窗口,然后在模式窗口中返回值到主窗口中
    function OpenEmp()
    {
    var url="../Employees/DeptEmployee.aspx";
    var array=window.showModalDialog(url,'','scrollbars=yes,top=0,left=0,resizable=no,status=no,toolbar=no,menubar=no,location=no,width=600,height=650');
    document.getElementById("txtEmpName").value=array[1];
    document.getElementById("txtEmpID").value=array[0];
    }模式窗口中返回值
    <script language="javascript">
    function ReturnNote(EmpID,RealName)
    {
             var array=new Array(EmpID,RealName);
    window.returnValue=array;
    window.opener=null;
    window.close();
    }
    </script>
      

  2.   

    http://dotnet.aspx.cc/ShowDetail.aspx?id=49ML4AO8-5PB3-4KNY-NJZD-LJOIOXV4M1X4