I am using this code to Download a file
I don't know correct way of checking error during downloading
Global $DownloadStatus = InetGet($url, $fileName, Default, $INET_DOWNLOADBACKGROUND)
While 1
$ArrayOFDownloadStatuts = InetGetInfo($DownloadStatus)
If Not $ArrayOFDownloadStatuts[4] = 0 Then
MsgBox(0,"Error","Error During Downloading")
ExitLoop
EndIf
If $ArrayOFDownloadStatuts[2] Then
MsgBox(0,"","Compelted")
ExitLoop
EndIf
WEnd
I am using that code but don't know why it gives error during downloading the file
is it wrong way of checking error or is there network error on my pc ?
thank you