Back to product page

CheckDone event


Fires when component has finished checking for new updates.

Syntax

  • Basic
Private Sub object_CheckDone(NewFiles, ErrorCode, ErrorText)
The CheckDone(object,NewFiles,ErrorCode,ErrorText) syntax has these parts:
objectA wodAppUpdate object.
NewFilesA Long value. Total number of new files that should be replaced.
ErrorCodeA Long value. Holds error number, if any.
ErrorTextA String value. Holds text description of the error, if any.

Remarks

This event fires when Check method completes. At this point Files and Messages collections are filled with information. You can now evaluate and change received information, or you can just proceed to the next step and call Download method.

Typically, and the simplest way, is for your code to look like this:
 
Private Sub Upd1_CheckDone(ByVal ErrorCode As Long, ByVal ErrorText As String)
   If Not ErrorCode Then
       Upd1.Download
   Else
       MsgBox ErrorText, vbOKOnly, "Error"
   End If
End Sub
 

NewFiles argument tells you if there are new files that need to be replaced at all. You could add one more if..then structure in the code and show message box "no new files found" when NewFiles = 0.

Platforms

Windows