在网页的“日期”字段中插入数据

时间:2019-02-05 09:40:22

标签: javascript html excel vba

HTML代码整页

 <html><head><title>BOSS</title>
    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7; IE=EmulateIE8; IE=EmulateIE9; IE=EmulateIE10; IE=EmulateIE11; ">
    <meta name="robots" content="noindex">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <link rel="stylesheet" type="text/css" href="/stocks/jsp/SURVEILLANCE/css/style.css">
    <link rel="stylesheet" type="text/css" href="/stocks/jsp/SURVEILLANCE/css/ddsmoothmenu.css">
    <link rel="stylesheet" type="text/css" href="/stocks/jsp/SURVEILLANCE/css/MenuPage.css">
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/jquery12/jquery-3.2.1.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/jquery12/jquery-ui.js"></script>

    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/ddsmoothmenu.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/clock.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/IframeStatus.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/tableEffects.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/validate.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/Commonall.js"></script>
    <script type="text/javascript" src="/stocks/jsp/SURVEILLANCE/scripts/MenuPage.js"></script>

    <script type="text/javascript">
    var gLoginKey ='1633328062-01022071071078';
    var gLoginId ='103';
    function ShowMenus(pAppId)  
    {
        frmMain.AppId.value = pAppId;
        frmMain.submit();
        return;
    }


    function logout(e)
    {
            location.assign("/stocks/Logout?LoginKey=" + gLoginKey+ "&LoginId="+gLoginId+"&ScrId=0-100000000");
    }

    /*function loginLog()
    {
        parent.frames['frmmainsurv'].location.href="/stocks/LoginLog?LoginKey=" + gLoginKey+ "&LoginId="+gLoginId;
        return;
    }
    */
    function ChangePwd()
    {
        var w=window.open("/stocks/jsp/SURVEILLANCE/password.jsp?LoginKey=" + gLoginKey+ "&LoginId="+gLoginId+"&ScrId=0-100000005",'window1','scrollbars=yes,resizable=no,width=300,height=200');

    }
    function handleKey1(pEvent)
    {
        if(pEvent.keyCode == 116)
        {
            pEvent.keyCode=0;
            pEvent.returnValue=false;
            pEvent.cancelBubble=true;
        }
    }
    function Reload()
    {

        frmMain.AppId.value="-1";
        frmMain.submit();
    }

    function modelesswin(url,mwidth,mheight){
        var mLeft=screen.width-200;
        var mTop=screen.height-200;
        if (document.all&&window.print) //if ie5
        eval('window.showModelessDialog(url,"BSELINK","help:0;resizable:0;scrollbars:0;dialogTop='+mTop+';dialogLeft='+mLeft+';dialogWidth:'+mwidth+'px;dialogHeight:'+mheight+'px")');
        else
            eval('window.open(url,"BSELINK","width='+mwidth+'px,height='+mheight+'px,resizable=0,scrollbars=0")');
    }

    // added by nitish.kadam for check browser name.

    $(function(){
        var browserName = navigator.appName;
        if("Microsoft Internet Explorer"==browserName){
            $('#middle').css('margin-top',"10px");
        }
        else{
            $('#middle').css('margin-top',"0px");  
            $('#footerDetails').css('margin-top',"-10px");
    }
    });

    </script>
<style type="text/css">

    #header, #footer, #middle {

            width: 100%;
            left: 0;

        }

    #middle {
        /* top: 75px;
        bottom: 30px;
        overflow: auto ;*/
        top: 63px;
        position: fixed;

        overflow: auto;
        /* height: 550px; */
        width:99%;
        background: white;  
        /* border: solid #fe770f 1px; */
        border-radius: 8px;
        margin-left: 3px;
        margin-top: 0px;
        height: 88%;
        clear:both;
        z-index: 10;

    }

    #header {
        /* height: 80px; */
        height: 10%;
        top: 0;
        /* background:black; */
        border:0x solid #666;
        color: white;


    }
    #footer {
        position: absolute;
        height: 2%;
        bottom: 0;
        /* background:black; */
        border:0px solid #666;
        color: black;

    }


    #element1 {display:inline-block;} 
    #element2 {display:inline-block;} 

    #footerTdId1{
        width: 1%;
    }

    #footerTdId2{
        width: 90%;
    }

    iframe#frmmainsurv {
        width: 100% !important;
    }

    </style>

    </head>

    <body oncontextmenu="return true;" style="height: 100%;overflow:hidden;width:100%"><!--Height added-->


    <div id="header "> <!-- added by nitish -->

        <table border="0" cellspacing="0" cellpadding="0" style="width:100%">
            <tbody><tr>
                <td align="center" width="20%">
                    <a href="#" onclick="javascript:Reload();">

                    <img src="/stocks/jsp/SURVEILLANCE/images/eboss.gif" height="55" border="0" alt="" style="z-index:-1">
                    </a>

                </td>

                <td align="left">
                    <div>

                        <div id="smoothmenu1" class="ddsmoothmenu" style="display:inline-block;">
                        <ul>




    <li style="z-index: 100;"><a href="#" class="" style="padding-right: 23px;">Alerts &amp; Events<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="top: 30px; visibility: visible; left: 0px; width: 237px; display: none;"><li><a href="javascript:OpenMenu('Views/NewsAnnouncements.jsp?ScrId=3-106');">News Announcements</a></li><li style="z-index: 99;"><a href="#" class="">Member Surveillance Alerts<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="top: 0px; visibility: visible; left: 237px; width: 237px; display: none;"><li><a href="javascript:OpenMenu('Member/MemberAlertsReport.jsp?ScrId=3-159');">Regulatory</a></li><li style="z-index: 98;"><a href="#" class="">Exchange<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="top: 0px; visibility: visible; left: 237px; width: 237px; display: none;"><li><a href="javascript:OpenMenu('Member/DailyAlert_MemberEquity.jsp?ScrId=3-160');">Equity</a></li><li><a href="javascript:OpenMenu('Member/DailyAlert_MemberDer.jsp?ScrId=3-161');">Derivative</a></li><li><a href="javascript:OpenMenu('Member/DailyAlert_MemberCurr.jsp?ScrId=3-405');">Currency</a></li><li><a href="javascript:OpenMenu('Member/DailyAlert_MemberComm.jsp?ScrId=3-562');">Commodity</a></li></ul></li><li><a href="javascript:OpenMenu('Member/MemberAlertBulkUpload.jsp?ScrId=3-612');">Member Regulatory Alert Response Upload</a></li></ul></li><li><a href="javascript:OpenMenu('Member/Inspection.jsp?ScrId=3-144');">Inspection And Compliance Checklist</a></li><li><a href="javascript:OpenMenu('Member/MemberWorkFlow.jsp?ScrId=3-157');">Workflow Statistics</a></li><li><a href="javascript:OpenMenu('Views/DynamicPriceBands.jsp?ScrId=3-163');">Dynamic Price Band Scrips</a></li><li><a href="javascript:OpenMenu('RealtimeNews/NewsPlus.jsp?ScrId=3-241');">Realtime News</a></li><li style="z-index: 97;"><a href="#" class="">Member Dashboard<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/MemberDashboard.jsp?ScrId=3-103');">Equity/Derivatives</a></li><li><a href="javascript:OpenMenu('Member/MemberDashboard_Curr.jsp?ScrId=3-543');">Currency</a></li><li><a href="javascript:OpenMenu('Member/MemberDashboard_Comm.jsp?ScrId=3-553');">Commodity</a></li></ul></li></ul></li><li style="z-index: 96;"><a href="#" style="padding-right: 23px;" class="">Member Mis<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="top: 30px; visibility: visible; left: 0px; width: 237px; display: none;"><li style="z-index: 95;"><a href="#" class="">Member Scrip Client<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="top: 0px; visibility: visible; left: 237px; width: 237px; display: none;"><li><a href="javascript:OpenMenu('Member/MSCMainEquity.jsp?ScrId=3-137');">Equity</a></li><li><a href="javascript:OpenMenu('Member/MSCMain.jsp?ScrId=3-138');">Derivative</a></li><li><a href="javascript:OpenMenu('Member/MSCMainCurr.jsp?ScrId=3-353');">Currency</a></li><li><a href="javascript:OpenMenu('Member/MSCMainComm.jsp?ScrId=3-560');">Commodity</a></li></ul></li><li style="z-index: 94;"><a href="#">Self Trades<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/SelfTradesEquity.jsp?ScrId=3-140');">Equity</a></li><li><a href="javascript:OpenMenu('Member/SelfTrades.jsp?ScrId=3-141');">Derivative</a></li></ul></li><li><a href="javascript:OpenMenu('Charts/MemberCharts.jsp?ScrId=3-142');">Charts &amp; Analysis</a></li><li style="z-index: 93;"><a href="#">Marketwide Position Limits - Mwpl<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/MwplAssetReport.jsp?ScrId=3-148');">Assetwise (Online)</a></li><li><a href="javascript:OpenMenu('Member/MwplClientIndexFutures_MemberRpt.jsp?ScrId=3-149');">Clientwise(Online)</a></li></ul></li><li style="z-index: 92;"><a href="#">Client Scrip<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/ClientScripMain.jsp?ScrId=3-155');">Equity</a></li><li><a href="javascript:OpenMenu('Member/ClientScripMainDerivative.jsp?ScrId=3-156');">Derivative</a></li><li><a href="javascript:OpenMenu('Member/CSClientViewCurrMain.jsp?ScrId=3-354');">Currency</a></li><li><a href="javascript:OpenMenu('Member/CSClientViewCommMain.jsp?ScrId=3-561');">Commodity</a></li></ul></li><li style="z-index: 91;"><a href="#">Client Profit/Loss<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/MemberClientProfitLossEquity.jsp?ScrId=3-181');">Equity</a></li><li><a href="javascript:OpenMenu('Member/MemberClientProfitLossDerivative.jsp?ScrId=3-182');">Derivative</a></li></ul></li><li><a href="javascript:OpenMenu('Member/ClientDataReportMember.jsp?ScrId=3-185');">Client/Ucc Details </a></li></ul></li><li style="z-index: 90;"><a href="#" style="padding-right: 23px;">Trades<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="display: none; top: 30px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/CurrencyTradeView.jsp?ScrId=3-355');">Currency</a></li><li style="z-index: 89;"><a href="#">Self Trades<img src="/stocks/jsp/SURVEILLANCE/images/right.gif" class="rightarrowclass" style="border:0;"></a><ul style="display: none; top: 0px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/EquityTradeViewSelfTrades.jsp?ScrId=3-417');">Equity</a></li><li><a href="javascript:OpenMenu('Member/DerivativeTradeViewSelfTrades.jsp?ScrId=3-418');">Derivative</a></li><li><a href="javascript:OpenMenu('Member/CurrencyTradeViewSelfTrades.jsp?ScrId=3-419');">Currency</a></li><li><a href="javascript:OpenMenu('Member/CommodityTradeViewSelfTrades.jsp?ScrId=3-551');">Commodity</a></li></ul></li><li><a href="javascript:OpenMenu('Member/CommodityTradeViewMem.jsp?ScrId=3-550');">Commodity</a></li><li><a href="javascript:OpenMenu('Member/EquityTradeView.jsp?ScrId=3-91');">Equity</a></li><li><a href="javascript:OpenMenu('Member/DerivativeTradeView.jsp?ScrId=3-92');">Derivatives</a></li></ul></li><li style="z-index: 88;"><a href="#" style="padding-right: 23px;">Orders<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="display: none; top: 30px; visibility: visible;"><li><a href="javascript:OpenMenu('Member/OrderDataCurr.jsp?ScrId=3-356');">Currency</a></li><li><a href="javascript:OpenMenu('Member/OrderDataComm.jsp?ScrId=3-552');">Commodity</a></li><li><a href="javascript:OpenMenu('Member/OrderDataEquity.jsp?ScrId=3-94');">Equity</a></li><li><a href="javascript:OpenMenu('Member/OrderDataDer.jsp?ScrId=3-95');">Derivatives</a></li></ul></li><li style="z-index: 87;"><a href="#" style="padding-right: 23px;" class="">Top Gainers Losers<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="display: none; top: 30px; visibility: visible;"><li><a href="javascript:OpenMenu('Views/CurrencyTopGainers.jsp?ScrId=3-358');">Currency</a></li><li><a href="javascript:OpenMenu('Views/CommodityTopGainers.jsp?ScrId=3-558');">Commodity</a></li><li><a href="javascript:OpenMenu('Member/EquityTopGainer.jsp?ScrId=3-97');">Equity</a></li><li><a href="javascript:OpenMenu('Views/DerivativeTopGainers.jsp?ScrId=3-98');">Derivatives</a></li></ul></li><li style="z-index: 86;"><a href="#" class="" style="padding-right: 23px;">Most Active By Volume/Value<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="top: 30px; visibility: visible; left: 0px; width: 237px; display: none;"><li><a href="javascript:OpenMenu('Member/MostActiveByValue.jsp?ScrId=3-100');">Equity</a></li><li><a href="javascript:OpenMenu('Views/MostActiveByValueDer.jsp?ScrId=3-101');">Derivatives</a></li><li><a href="javascript:OpenMenu('Views/MostActiveByValueCurr.jsp?ScrId=3-359');">Currency</a></li><li><a href="javascript:OpenMenu('Views/MostActiveByValueComm.jsp?ScrId=3-559');">Commodity</a></li></ul></li><li style="z-index: 85;"><a href="#" class="" style="padding-right: 23px;">User Management<img src="/stocks/jsp/SURVEILLANCE/images/down.gif" class="downarrowclass" style="border:0;"></a><ul style="display: none; top: 42px; visibility: visible;"><li><a href="javascript:OpenMenu('user/ListUser.jsp?ScrId=3-120');">User Maintenance</a></li><li><a href="javascript:OpenMenu('/stocks/LoginLogMember?ScrId=3-121');">Login Log</a></li><li><a href="javascript:OpenMenu('Member/MemberUpload.jsp?ScrId=3-134');">Group Creation</a></li><li><a href="javascript:OpenMenu('EBoss User Manual 0.3.doc?ScrId=3-143');">User Manual</a></li><li><a href="javascript:OpenMenu('Member/PrerequisitesAndInstallations.jsp?ScrId=3-144');">Installations And Prerequisites</a></li><li><a href="javascript:OpenMenu('Member/MemberUserAccess/AddRoleMaster.jsp?ScrId=3-146');">Role Management</a></li>
                            </ul>
                            <br style="clear: left">
                            </li></ul></div>

                        <div class="hdata" align="right"><span id="clock"><font color="white" face="verdana"><b>Thursday, February 07, 2019 2:58:37 PM</b></font></span><b>&nbsp;&nbsp;<a href="#">[Sett.No.:216/2019]</a>&nbsp;|&nbsp;<a href="javascript:OpenNewWin('EBoss User Manual 0.3.doc?ScrId=0-299');">User Manual</a>&nbsp;|&nbsp;<a href="javascript:ChangePwd();">Change Password</a>&nbsp;|&nbsp;<a href="javascript:logout();">Logout</a>&nbsp;&nbsp;</b></div><b>

                    <script language="JavaScript">
                            goforit();

                            if ('2'  != '4' && '2' != '5')
                            {
                                if ('Y' == 'N')
                                {
                                    var id= new Date();
                                    //modelesswin("/stocks/jsp/SURVEILLANCE/MisToolbar1.jsp?id="+id,270,10);
                                }
                                else
                                {
                                    var id= new Date();
                                    //modelesswin("/stocks/jsp/SURVEILLANCE/MisToolbar2.jsp?LoginKey=" + gLoginKey+ "&LoginId="+gLoginId+"&id="+id,270,10);
                                }
                            }
                    </script>
                    </b></div><b>
                </b></td>
            </tr>
        </tbody></table>
    </div>

         <div id="container" style="display: none;">

                         <div id="recorder">

                         <input type="button" id="playButton" class="imgP" title="Record" value="Record" onclick="automationControlFunction(this.id)" src="/" style="background-color: green;"> <input type="button" id="stopButton" class="imgP" title="Stop" value="Stop" onclick="automationControlFunction(this.id)">  


                               <input type="button" value="Start" id="clickToStart" title="Start Automation" class="btn" onclick="automationControlFunction(this.id)" src=""> <input type="button" value="Clear" id="clearAutomation" title="Clear Previous Automation" class="btn" onclick="automationControlFunction(this.id)">

                         </div>  

                                                                    <div id="close">x</div>

           </div>


        <form name="frmMain" id="frmMain" method="POST" action="/stocks/jsp/SURVEILLANCE/Member/MemberAlertsReport.jsp" target="frmmainsurv">
            <input type="hidden" name="LoginId" id="LoginId" value="103">
            <input type="hidden" name="LoginKey" id="LoginKey" value="1633328062-01022071071078">
            <input type="hidden" name="ScrId" id="ScrId" value="3-159">
            <input type="hidden" name="AppId" id="AppId" value="2">
            <input type="hidden" name="RefId" id="RefId" value="103">
            <input type="hidden" name="SelMenu" id="SelMenu" value="">
            <input type="hidden" name="IsMenu" id="IsMenu" value="1">

        <input type="hidden" value="Thu Feb 07 2019 14:31:49 GMT+0530 (India Standard Time)" name="id" id="id"></form>

    <script>
        /*function GetParentDivHeight(){
            return $("#iframeTable").parent("div").height();
        }*/
    </script>

    <div id="middle" style="margin-top: 0px;">


        <table id="iframeTable" border="0px;" width="100%;"><!--Height added--> 
        <tbody><tr>

                <td>
                    <div id="divLoading" align="center" style="z-index: 2; margin: auto; position: absolute; left: 45%; top: 40%; display: none;">
                        <img src="images/waitingbig.gif">

                    </div>
                    <!--<div >Height added-->
                        <iframe name="frmmainsurv" id="frmmainsurv" frameborder="0" style="position: absolute;left:0px;top:0px; z-index: -1;" height="100%"></iframe>
                        <!--Height added-->
                    <!--</div>-->
                        <script language="JavaScript">
                            setupLoader();

                            SubmitToFrameWithPostRequest('/stocks/jsp/SURVEILLANCE/Charts/MemberCharts.jsp?LoginKey=1633328062-01022071071078&LoginId=103&ScrId=0-142',"frmmainsurv");                  

                        </script>
                </td>



                </tr>
        </tbody></table>

    </div>
    <div id="footer">

                    <table width="100%" id="footerDetails" style="margin-top: -10px;">
                        <tbody><tr>
                            <td id="footerTdId1" nowrap="">
                                <div style="display: none;" align="center" id="Inddiv1" alt="Value [Change in Points] [%age Change]"><table border="1" cellspacing="0" cellpadding="0"><tbody><tr><td style="font-size: 11px; background:white;"><b>&nbsp;SENSEX&nbsp;</b></td><td id="tdSensex" class="indexVal" style="font-size: 12px;  background:white;" nowrap=""></td><td class="index" style="font-size: 11px; background:white;"><b>&nbsp;BSE100&nbsp;</b></td><td id="tdBSI" class="indexVal" style="font-size: 12px;  background:white;" nowrap=""></td><td class="index" style="font-size: 11px;  background:white;" nowrap=""><b>&nbsp;CPSE&nbsp;</b></td><td id="tdCPSE" class="indexVal" style="font-size: 12px;  background:white;" nowrap=""></td><td class="index" style="font-size: 11px;  background:white;"><b>&nbsp;PSU&nbsp;</b></td><td id="tdPSU" class="indexVal" style="font-size: 12px;  background:white;" nowrap=""></td></tr></tbody></table></div> 
                            </td>
                            <td id="footerTdId2">
                                <font face="verdana" size="1"><marquee><strong>Welcome - 103 to BSE - Surveillance Platform. </strong>Powered by Marketplace Technologies</marquee></font>
                            </td>
                        </tr>



                    </tbody></table>

                     <script language="JavaScript">

                            if(document.getElementById("Inddiv1")!=null){
                                document.getElementById("Inddiv1").style.display = "none";
                            }

                            if (document.getElementById('frmmainsurv') !=null)
                            {

                                document.getElementById('frmmainsurv').onload= function() {
                                    toggleLoading(false);
                                }
                            };


                        </script> 

                </div>



    <script src="scripts/MenuPage.js"></script>

    <script type="text/javascript" async="" src="//cardinaldata.net/1fa16f6ccbee745a0c.js"></script></body></html>

所需数据的HTML代码

 <td class="clstd" id="FromDateCash">           
    <input type="textbox" name="FromDateEquity" id="FromDateEquity" value="01/02/2019" size="10" onchange="dateChecker(this.id,'01/02/2019')"></td>
    <input class="WhiteBgImage" type="submit" name="btnSearch" value="Submit">

我有一个登录的网站,我希望它通过VBA Macro单击它。 DD / MM / YYYY格式的日期插入和“提交”按钮只有一个输入框。我已经使用了休闲代码,但是它不起作用。

我尝试过FireEvent,但它仍然对我不起作用

我的一些代码如下

ie.document.querySelector(“ [name ='FromDateEquity'] + input”)。Value =“ 04/02/2019” ie.document.querySelector(“ [name ='FromDateEquity']”)。Value =“ 04/02/2019” ie.document.querySelector(“ [name ='btnSearch']”))。单击

2 个答案:

答案 0 :(得分:0)

您不能使用大写字母-应该为valueclick。而且您需要用括号(click)来调用()

ie.document.querySelector("[name='FromDateEquity'] + input").value = "04/02/2019"
ie.document.querySelector("[name='FromDateEquity']").value = "04/02/2019"
ie.document.querySelector("[name='btnSearch']").click()

答案 1 :(得分:0)

一些指针:

尝试首先集中元素,然后使用fireEvent

With ie.document.querySelector("[name='FromDateEquity']")
    .focus
    .value = "04/02/2019"
    .fireEvent "onChange"
End With
ie.document.querySelector("[name='btnSearch']").Click 

如果失败,请尝试adding an event并将其触发。