Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

264
Visualizações
Invoking .Click event in Powershell

I'm trying to click on the login button for the page in the below file / url.

https://ufile.io/nryil

For some reason my code doesn't work. I've been messing with it for a day now. I'm kind of new to powershell so I'm not sure if this is something that's not capable, or if I'm missing something, but this is the latest code.

$username = username
$password = password
$ie = New-Object -com InternetExplorer.Application
$ie.visible=$true
$ie.navigate("192.168.1.10/designs/imm/index.php")
while( $ie.busy){Start-Sleep 10}
$secLink = $ie.Document.getElementsByTagName('A') | Where-Object {$_.innerText -eq 'Continue to this website (not recommended).'}
$secLink.click()
while( $ie.busy){Start-Sleep 10}
while($ie.ReadyState -ne 4) {start-sleep -m 20}
$ie.Document.IHTMLDocument3_getElementById("user").value = $username
$ie.Document.IHTMLDocument3_getElementById("password").value = $password
$link = $ie.Document.IHTMLDocument3_getElementsByName("Login").click
$link.click

I also just downloaded IMacros free trial to see how it's responding. I captured the below

element = driver.findElement(By.id("btnLogin_label"));
element.click();
element = driver.findElement(By.class("dijitOffScreen"));
element.click();

I even tried the below code after seeing that and still got nothing.

    $link = $ie.Document.IHTMLDocument3_getElementById('btnLogin_Label') | Where-Object {$_.class -eq 'dijitOffScreen'}
    $link.click

If I switch it to the below I get a "overload definitions void click()"

  $link = $ie.Document.IHTMLDocument3_getElementById('btnLogin_Label')
  $link.click
over 4 years ago · Santiago Trujillo
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda