📅  最后修改于: 2022-03-11 14:49:03.631000             🧑  作者: Mango
Public Function IsURLGood(url As String)
Dim request As Object
Set request = CreateObject("WinHttp.WinHttpRequest.5.1")
On Error GoTo haveError
With request
.Open "HEAD", url
.Send
IsURLGood = .Status
End With
Exit Function
haveError:
IsURLGood = Err.Description
End Function