- Codice: Seleziona tutto
Sub NAVIGA()
myURL = "https://www.xxxxxxxxxx.it/lr/home"
If Sheets("GERARCHIA").Range("H3").Value = "" Then
Exit Sub
Else
If Sheets("GERARCHIA").Range("H2").Value = "" Then
Exit Sub
End If
'
If IE Is Nothing Then Set IE = CreateObject("InternetExplorer.Application")
'
With IE
.Navigate myURL
.Visible = True
Do While .Busy: DoEvents: Loop 'Attesa not busy
Do While .ReadyState <> 4: DoEvents: Loop 'Attesa documento
End With
myLogin = Sheets("Firme").Range("D1").Value
myPassw = Sheets("GERARCHIA").Range("H3").Value
IE.document.all("username").Value = myLogin
IE.document.all("password").Value = myPassw
Set myColl = IE.document.getElementsByClassName("button-wrap")
myColl(0).getElementsByTagName("button")(0).Click
Do While IE.Busy: DoEvents: Loop 'Attesa not busy
IE.Navigate Sheets("Firme").Range("F1").Value
Set IE = Nothing
End If
End Sub
Grazie per l'attenzione