16,555
社区成员
发帖
与我相关
我的任务
分享
Private Function GetFtpFileSize(ByVal url As String) As Long
Dim reqFtp As FtpWebRequest
reqFtp = CType(FtpWebRequest.Create(New Uri(url)), FtpWebRequest)
reqFtp.Proxy = Nothing
reqFtp.Method = WebRequestMethods.Ftp.GetFileSize
Dim response As WebResponse
response = reqFtp.GetResponse()
Return response.ContentLength()
End Function