向这样一段代码如何能用VBS确定点击事件?   http://210.22.124.135:9383/unicom/speedtest/index.shtml 原网站

解决方案 »

  1.   

    asp ?
      

  2.   

    <div class="bb">
    <a onclick="check()" style="cursor: pointer;">&nbsp;</a>
    </div>  抓取第一个按钮<div class="bb">
    <input type="button" class="button_a" value="同&nbsp;&nbsp;意"
    onclick="agreehome();" style="cursor: pointer;" />
    &nbsp;&nbsp;
    <input type="button" class="button_a" value="不同意"
    onclick="rethome()" style="cursor: pointer;" />
    </div>抓取第二个按钮
    <a href="more_test.shtml" class="aa">继 续</a>抓取第三个按钮<a href="download_test.shtml" class="button_e"><img
    src="../images/icon05.gif" /><span class="aa">下载测速</span>
    <p class="clear bb">您可以通过下载测速功能测出宽带的近似速度</p>
    </a>抓取第四个按钮
    <a href="#" class="button_b fb" id="startTest" onclick="startTest();">开始</a><a
    href="#" class="button_b fb" id="stopTest" onclick="stopTest();">取消</a>
    抓取地五个按钮
      

  3.   

    http://www.autohotkey.com ?
    按键精灵 ?
    API SendInput ?
      

  4.   

    我之前写过一个通用函数:http://bbs.csdn.net/topics/392078403你要在vb里使用,引入一个webbrowser,然后就好控制了。
    getElementsByAttributes(webbrowser1,"onclick='check()'")(0).click
    getElementsByAttributes(webbrowser1,"onclick='agreehome();'")(0).click
    getElementsByAttributes(webbrowser1,"href='more_test.shtml'")(0).click
    getElementsByAttributes(webbrowser1,"href='download_test.shtml'")(0).click
    getElementsByAttributes(webbrowser1,"onclick='startTest();'")(0).click
    注意控制好它们的时间间隔。
      

  5.   

    为啥要点击?直接访问  javascript:check 就行啦。或者Document.parentWindow.execScript("check")