Hello
I was wondering how do i VBA - Get data from a password protected website what would i need to add to this code
I was wondering how do i VBA - Get data from a password protected website what would i need to add to this code
VBA Code:
Sub Get_Data()
'Copy web page to sheet1
On Error GoTo error
Application.ScreenUpdating = False
With Sheets("Sheet1").QueryTables.Add(Connection:= _
"URL;[URL='https://virusncov.com']Coronavirus 2019-nCov Statistics Update (Live)[/URL]", _ ' Change address
Destination:=Sheets("Sheet1").Range("A10"))
.BackgroundQuery = True
.TablesOnlyFromHTML = True
.Refresh BackgroundQuery:=False
.SaveData = True
End With
error:
Application.ScreenUpdating = True
End Sub
Last edited by a moderator: