Yes.
Sub Main()
Dim c As Range, glb_origCalculationMode As Integer
On Error GoTo EndSub
glb_origCalculationMode = Application.Calculation
With Application
.Calculation = xlCalculationManual
.ScreenUpdating = False
.EnableEvents = False
.DisplayAlerts = False
.Cursor = xlWait
.StatusBar = "Running Main()..."
.EnableCancelKey = xlErrorHandler
End With
For Each c In Range("A2", Range("A2").End(xlDown))
c.Offset(, 1).Value = FileSize(c.Value2)
Next c
EndSub:
With Application
.Calculation = glb_origCalculationMode
.ScreenUpdating = True
.EnableEvents = True
.DisplayAlerts = True
.CalculateBeforeSave = True
.Cursor = xlDefault
.StatusBar = False
.EnableCancelKey = xlInterrupt
End With
End Sub
'http://www.pcreview.co.uk/threads/file-size-of-web-file-via-url.3233105/
Function FileSize(sURL As String)
Dim oXHTTP As Object
Set oXHTTP = CreateObject("MSXML2.XMLHTTP")
oXHTTP.Open "HEAD", sURL, False
oXHTTP.send
If oXHTTP.Status = 200 Then
FileSize = oXHTTP.getResponseHeader("Content-Length")
Else
FileSize = -1
End If
End Function