dajun 发表于 2010-4-22 16:56:47

[已解决]如何点击菜单项

本帖最后由 dajun 于 2010-4-29 23:51 编辑

<link href="/SPC/theme/style/css.css" rel="stylesheet" type="text/css">





<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>菜单</title>
<link href="../theme/style/css.css" rel="stylesheet" type="text/css">
</head>
<script src="../javascript/allow.js"></script>
<script src="../javascript/common.js"></script>
<script language="JavaScript">
        function setMainFrameHeight(){
                var mainFrameHeight=this.document.body.scrollHeight;
                SetCookie ("mainFrameHeight", mainFrameHeight,365);
        }

        //功能访问统计
        function statClick(t1){
                functionCounter.location.href = "../ass/funClickStat.do?funId="+t1;
                SetCookie ("funInitFlag", '1',365);;//改变登陆标记,为返回上级使用
        }
       
        function pageInit(){
                var divObj=document.getElementById("Layer1");
                divObj.style.height=this.document.body.scrollHeight;
                setMainFrameHeight();
        }

//菜单显示控制       
var showsubmenu_sid=null;
function showsubmenu(sid)
{
        if(showsubmenu_sid!=null && sid!=showsubmenu_sid)
        {
                eval( showsubmenu_sid + ".style.display=\"none\";");
                showsubmenu_sid=sid;
        }
        if(showsubmenu_sid==null){
                showsubmenu_sid=sid;
        }
}

//弹出的四级菜单窗口
var popThridMenuWin=null;

//弹出的三级菜单窗口的二级菜单的TD元素
var popThridMenuSencondMenuTd=null;

//四级菜单浮动框显示
function showThridMenu(sencondMenuTD,fundID,size)
{               
        //if(popThridMenuSencondMenuTd!=null)
        //        popThridMenuSencondMenuTd.className='';
       
        //sencondMenuTD.className='zy_left_text2';
        //popThridMenuSencondMenuTd=sencondMenuTD;
       
        popThridMenuWin=window.createPopup();
       
        var style=style = popThridMenuWin.document.createElement('link');
    style.rel = 'stylesheet';
    style.type = 'text/css';
    style.href = "../theme/style/css.css";
        popThridMenuWin.document.getElementsByTagName('head').appendChild(style);
        var objStr=document.getElementById(fundID);
        //得到浮动框的高度
        var popHight=26*size+1;
        popThridMenuWin.document.body.innerHTML=objStr.innerHTML;
        popThridMenuWin.show(131,0,120,popHight,sencondMenuTD);
}

function hiddenThridMenu()
{       
        if(popThridMenuWin!=null)
        {
                popThridMenuWin.hide();
        }
}

function clickThridMenu(url)
{                       
        top.mainFrame.location=url;
        hiddenThridMenu();
}
</script>
<body onLoad="pageInit()">
<table width="100%" height="100%" border="0" cellspacing="0" cellpadding="0" valign="top"bgcolor="#f6f9fd">
<tr>
<td width="7"></td>
<td valign="top" width="193">
<div id="Layer1" style="position:absolute; width:100%; z-index:0; overflow: auto; visibility: visible">
<table width="176" border="0" cellspacing="" cellpadding="0" >
      <tr>
         <td height="10"></td>
      </tr>

        <tr>
          <td height="26" id="menu_SCML01" onClick="showsubmenu('menu_SCML01_list');showOrHideMenu(this);"
                                  style="cursor:hand" background="../theme/newImg/cd-bg.gif">
          <table width="176" height="22" border="0" cellspacing="0" cellpadding="0" >
                <tr>
                  <td width="16">&nbsp;</td>
                  <td width="140"><strong>计划管理</strong></td>
                  <td width="20"><img src="../theme/newImg/cd-dn.gif" width="12" height="12" id="menu_SCML01_icon"></td>
                </tr>
          </table>
          </td>
        </tr>
        <tr id="menu_SCML01_list" style="display:none;">
          <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
         <td height="4"></td>
      </tr>
                  <tr>
            <td><img src="../theme/newImg/cd-01.gif" width="176" height="6"></td>
      </tr>
          
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/factPlanCom.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|计划管理|生产计划完成情况统计');statClick('SCML0105');">
                      生产计划完成情况统计</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/tranPlanCom.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|计划管理|调拨计划完成情况统计');statClick('SCML0106');">
                      调拨计划完成情况统计</a>
                 
          </td>
         
         
                </tr>
      
      <tr>
         <td><img src="../theme/newImg/cd-03.gif" width="176" height="6"></td>
      </tr>
          </table></td>
        </tr>
      <tr>
         <td height="6"></td>
      </tr>

        <tr>
          <td height="26" id="menu_SCML02" onClick="showsubmenu('menu_SCML02_list');showOrHideMenu(this);"
                                  style="cursor:hand" background="../theme/newImg/cd-bg.gif">
          <table width="176" height="22" border="0" cellspacing="0" cellpadding="0" >
                <tr>
                  <td width="16">&nbsp;</td>
                  <td width="140"><strong>班时产量填报</strong></td>
                  <td width="20"><img src="../theme/newImg/cd-dn.gif" width="12" height="12" id="menu_SCML02_icon"></td>
                </tr>
          </table>
          </td>
        </tr>
        <tr id="menu_SCML02_list" style="display:none;">
          <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
         <td height="4"></td>
      </tr>
                  <tr>
            <td><img src="../theme/newImg/cd-01.gif" width="176" height="6"></td>
      </tr>
          
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/shiftOutput.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|班时机台产量录入');statClick('SCML0201');">
                      班时机台产量录入</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/shiftOutput.do?requestType=init&optionType=11&reportflag=report" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|班时机台产量审核');statClick('SCML0203');">
                      班时机台产量审核</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/pasteCode.do?requestType=initFrame" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|无码补贴码录入');statClick('SCML0205');">
                      无码补贴码录入</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/pasteCode.do?requestType=initCheckFrame" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|无码补贴码审核');statClick('SCML0206');">
                      无码补贴码审核</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/expandSilk.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|膨胀烟丝录入');statClick('SCML0214');">
                      膨胀烟丝录入</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/expandSilk.do?requestType=init&optionType=7" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|班时产量填报|膨胀烟丝审核');statClick('SCML0215');">
                      膨胀烟丝审核</a>
                 
          </td>
         
         
                </tr>
      
      <tr>
         <td><img src="../theme/newImg/cd-03.gif" width="176" height="6"></td>
      </tr>
          </table></td>
        </tr>
      <tr>
         <td height="6"></td>
      </tr>

        <tr>
          <td height="26" id="menu_SCML03" onClick="showsubmenu('menu_SCML03_list');showOrHideMenu(this);"
                                  style="cursor:hand" background="../theme/newImg/cd-bg.gif">
          <table width="176" height="22" border="0" cellspacing="0" cellpadding="0" >
                <tr>
                  <td width="16">&nbsp;</td>
                  <td width="140"><strong>生产情况日报</strong></td>
                  <td width="20"><img src="../theme/newImg/cd-dn.gif" width="12" height="12" id="menu_SCML03_icon"></td>
                </tr>
          </table>
          </td>
        </tr>
        <tr id="menu_SCML03_list" style="display:none;">
          <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
         <td height="4"></td>
      </tr>
                  <tr>
            <td><img src="../theme/newImg/cd-01.gif" width="176" height="6"></td>
      </tr>
          
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/report/rpt.jsp?report_id=14" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|产销存日报');statClick('SCML0301');">
                      产销存日报</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/rep/shiftOutputDay.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|班时机台产量日报');statClick('SCML0302');">
                      班时机台产量日报</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/spc/shiftOutputTotal.do" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|班时机台产量查询-企业');statClick('SCML0303');">
                      班时机台产量查询-企业</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/spc/chuSiHistory.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|储丝柜储丝量日报');statClick('SCML0307');">
                      储丝柜储丝量日报</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/spc/noCodeAndSpare.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|半成品(备货)统计表');statClick('SCML0308');">
                      半成品(备货)统计表</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/expandSilkRpt.do?requestType=initSpec" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产情况日报|膨胀烟丝统计表');statClick('SCML0312');">
                      膨胀烟丝统计表</a>
                 
          </td>
         
         
                </tr>
      
      <tr>
         <td><img src="../theme/newImg/cd-03.gif" width="176" height="6"></td>
      </tr>
          </table></td>
        </tr>
      <tr>
         <td height="6"></td>
      </tr>

        <tr>
          <td height="26" id="menu_SCML04" onClick="showsubmenu('menu_SCML04_list');showOrHideMenu(this);"
                                  style="cursor:hand" background="../theme/newImg/cd-bg.gif">
          <table width="176" height="22" border="0" cellspacing="0" cellpadding="0" >
                <tr>
                  <td width="16">&nbsp;</td>
                  <td width="140"><strong>生产经营统计</strong></td>
                  <td width="20"><img src="../theme/newImg/cd-dn.gif" width="12" height="12" id="menu_SCML04_icon"></td>
                </tr>
          </table>
          </td>
        </tr>
        <tr id="menu_SCML04_list" style="display:none;">
          <td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
         <td height="4"></td>
      </tr>
                  <tr>
            <td><img src="../theme/newImg/cd-01.gif" width="176" height="6"></td>
      </tr>
          
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/productAnalyse.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产经营统计|产品分析');statClick('SCML0401');">
                      产品分析</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/analy/cdcReport.do?requestType=init" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产经营统计|产调存日报表');statClick('SCML0416');">
                      产调存日报表</a>
                 
          </td>
         
         
                </tr>
      
                <tr>
                  <td height="22" align="left"background="../theme/newImg/cd-02.gif"> &nbsp;&nbsp;&nbsp;<img src="../theme/newImg/ar.gif" width="7" height="7">
                  
                          <a href="/SPC/report/dwr_rpt.jsp?report_id=1" target="mainFrame"
                      onClick="top.systemInfoFrame.setNavBar('|生产管理|生产经营统计|产销存月统计-企业');statClick('SCML0411');">
                      产销存月统计-企业</a>
                 
          </td>
         
         
                </tr>
      
      <tr>
         <td><img src="../theme/newImg/cd-03.gif" width="176" height="6"></td>
      </tr>
          </table></td>
        </tr>
      <tr>
         <td height="6"></td>
      </tr>

</table>
</div>
</td>
</tr>
</table>
<IFRAME border=0 name=functionCounter marginWidth=0 frameSpacing=0 marginHeight=0
              src="" frameBorder=0 noResizescrolling="no" width=0 height=0 vspale="0"></IFRAME>
</body>
</html>

ruxin.zhang 发表于 2010-4-25 21:59:50

好像有点小复杂

dajun 发表于 2010-4-29 09:48:29

$onFrame = _IEFrameGetObjByName($oIE, "navBarFrame")

        _IELinkClickByText($onFrame, "生产管理")
        Sleep(1000)

        $olFrame = _IEFrameGetObjByName($oIE, "leftFrame")
        _IELinkClickByText($olFrame, "生产计划完成情况统计")

dajun 发表于 2010-5-6 21:12:50

do
$Number = InputBox('提示!', '请随便输入字符!',@YEAR&@MON,'',200,130)
If $Number = "" ThenExit
until StringRegExp ($Number, '^\d{4}(|0|1)$', 0)=1
MsgBox(64,"","ok")

hollandmfq 发表于 2014-5-13 14:01:20

雷锋精神传天下!谢谢分享!
页: [1]
查看完整版本: [已解决]如何点击菜单项