POWERSHELL Selenium-我正在尝试在POWERSHELL中的同一脚本中获取2个URL。这是我的代码,有什么建议吗?

POWERSHELL Selenium-我正在尝试在POWERSHELL中的同一脚本中获取2个URL。这是我的代码,有什么建议吗?,powershell,selenium,automation,Powershell,Selenium,Automation,第一部分登录到web应用程序,第二个url用于访问web应用程序内部的模块。有什么建议吗 $workingPath = 'C:\selenium' $env:Path += ";$workingPath" Add-Type -Path "$($workingPath)\WebDriver.dll" $ChromeDriver = New-Object OpenQA.Selenium.Chrome.ChromeDriver $temp = $ChromeDr

第一部分登录到web应用程序,第二个url用于访问web应用程序内部的模块。有什么建议吗

$workingPath = 'C:\selenium'
$env:Path += ";$workingPath"
Add-Type -Path "$($workingPath)\WebDriver.dll"
$ChromeDriver = New-Object OpenQA.Selenium.Chrome.ChromeDriver
$temp = $ChromeDriver.Navigate()
$temp.GoToURL('https://idahouatupgrade.precinctcentral.com/TED/SecuritySetupMgmt/Security/Login.aspx')
$ChromeDriver.FindElementById("ASPxTextboxUsername").SendKeys('Thisistheusername')
$ChromeDriver.FindElementById("ASPxTextboxPassword").SendKeys('thisisthepassword')
$ChromeDriver.FindElementById("ASPxButtonLogin").Click()
$temp.GoToURL('https://idahouatupgrade.precinctcentral.com/TED/ElectionDesk/Home.aspx')