FTP操作失败返回码

 Case 12003:
'extended error. Retrieve the details using
'the InternetGetLastResponseInfo API.

sBuffer = Space$(256)
nBuffer = Len(sBuffer)

If InternetGetLastResponseInfo(lErrorCode, _
sBuffer, _
nBuffer) Then
GetErr = StripNull(sBuffer)
Else
GetErr = "Extended error returned from server."
End If

Case 12004: GetErr = _
"An internal error has occurred."
Case 12005: GetErr = _
"URL is invalid."
Case 12006: GetErr = _
"URL scheme could not be recognized, or is not supported."
Case 12007: GetErr = _
"Server name could not be resolved."
Case 12008: GetErr = _
"Requested protocol could not be located."
Case 12009: GetErr = _
"Request to InternetQueryOption or InternetSetOption" & _
" specified an invalid option value."
Case 12010: GetErr = _
"Length of an option supplied to InternetQueryOption or" & _
" InternetSetOption is incorrect for the type of" & _
" option specified."
Case 12011: GetErr = _
"Request option can not be set, only queried. "
Case 12012: GetErr = _
"Win32 Internet support is being shutdown or unloaded."
Case 12013: GetErr = _
"Request to connect and login to an FTP server could not" & _
" be completed because the supplied user name is incorrect."
Case 12014: GetErr = _
"Request to connect and login to an FTP server could not" & _
" be completed because the supplied password is incorrect. "
Case 12015: GetErr = _
"Request to connect to and login to an FTP server failed."
Case 12016: GetErr = _
"Requested operation is invalid. "
Case 12017: GetErr = _
"Operation was canceled, usually because the handle on" & _
" which the request was operating was closed before the" & _
" operation completed."
Case 12018: GetErr = _
"Type of handle supplied is incorrect for this operation."
Case 12019: GetErr = _
"Requested operation can not be carried out because the" & _
" handle supplied is not in the correct state."
Case 12020: GetErr = _
"Request can not be made via a proxy."
Case 12021: GetErr = _
"Required registry value could not be located. "
Case 12022: GetErr = _
"Required registry value was located but is an incorrect" & _
" type or has an invalid value."
Case 12023: GetErr = _
"Direct network access cannot be made at this time. "
Case 12024: GetErr = _
"Asynchronous request could not be made because a zero" & _
" context value was supplied."
Case 12025: GetErr = _
"Asynchronous request could not be made because a" & _
" callback function has not been set."
Case 12026: GetErr = _
"Required operation could not be completed because" & _
" one or more requests are pending."
Case 12027: GetErr = _
"Format of the request is invalid."
Case 12028: GetErr = _
"Requested item could not be located."
Case 12029: GetErr = _
"Attempt to connect to the server failed."
Case 12030: GetErr = _
"Connection with the server has been terminated."
Case 12031: GetErr = _
"Connection with the server has been reset."
Case 12036: GetErr = _
"Request failed because the handle already exists."
Case Else: GetErr = _
"Error details not available."


If you found this post to be helpful, please rate it to let others know it was useful.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值