VBS Operation JS Page Element instance

Source: Internet
Author: User
Tags tagname

' ==========================================================================

' VBScript Source File--Created with SAPIEN Technologies primalscript 4.0

' NAME:

' Author:microsoft, Microsoft
' DATE:2014/8/14

' COMMENT:

' ==========================================================================

Dim ie,obj
Set Ie =wscript.createobject ("Internetexplorer.application")
Ie.navigate "Www.baidu.com"
Wscript.Sleep 1000
Ie.menubar=1 ' Ïôê¾ie¶ôïó²ëµ¥à¸
Ie. Addressbar=1 ' Ïôê¾ie¶ôïóµøö À¸
Ie. Toolbar=1 ' Ïôê¾ie¶ôï󹤾ßà¸
Ie. Statusbar=0 ' ²»ïôê¾ie¶ôïóx´ì¬à¸
Ie. Fullscreen=0 ' È«æữie¶ôïó
Ie. Resizable=0 ' Éèöãie¶ôïó´óð¡êç Ñ¿éòô±»¸ä¶¯
Ie.visible=1 ' Éèöãêç ñ¿é¼û


Set obj = Ie.document

For I=0 to Obj.all.length-1

If Obj.all (i). Tagname= "INPUT" Then
If Obj.all (i). value= "°ù¶èò»ïâ" Then
Wscript.Sleep 1000
Obj.all (i). click
End If

End If

Next


Set obj=nothing


' ================================================


' X=ie.document.getelementsbytagname ("form")
' Wscript.Sleep 1000
' X.submit
' =======================================================


' Wscript.Sleep 1000
' Set obj = ie.document

"" "" "Ä¿µä:²âêôµçâ¼°´å¥"
' For i=0 to Obj.all.length-1
' If obj.all (i). Tagname= "Input" then
' If Obj.all (i). value= "°ù¶èò»ïâ" Then
' Wscript.Sleep 1000
' Obj.all (i). click
' End If
' End if
' Next

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.