gpt4 book ai didi

powershell - 如何使用PowerShell单击图像?

转载 作者:行者123 更新时间:2023-12-03 00:14:52 25 4
gpt4 key购买 nike

我正在尝试使用PowerShell登录网页,但是“登录”按钮的编码如下:

<input type="image" src="http://tolimages.traderonline.com/i... alt="Sign In"> 

我应该在PowerShell中使用什么功能才能单击图片并因此登录?

谢谢!

最佳答案

尝试以下操作:

$url = "http://xxxxxxxxxx/"
$ie = New-Object -ComObject InternetExplorer.Application
$ie.Visible = $true
$ie.Navigate($url)
While ($ie.Busy) { Start-Sleep -Milliseconds 400 }
$Link = $ie.document.getElementsByTagName("input") | where-object {$_.type -eq "image"}
$Link.click();

关于powershell - 如何使用PowerShell单击图像?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37840917/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com