Initializes the connection to the DbNet network according to the specified HW and database description.
The method performs the initialization of the object. Until the initialization is successful, the other methods of the object cannot be used, because they will end with the error "not initialized". The exceptions are the version checking, information checking, and time conversion methods, which can be used without initialization.
If it is necessary to change the value of the DirectEvents
property then this change must be made before the initialization methods are executed.
It is highly recommended to test the return value of the initialization methods and to treat the application for the possibility of initialization failure. Some errors (for example "wrong WID") are the result of errors in parameterizing and using the object, and can be eliminated relatively early. However, initialization can always result in the unavailability of the HW connection resource (COM, DOCK), which leads to subsequent application failure.
If the initialization method is called on the object then the de-initialization method Done
must always be called before the object is cancelled. regardless, whether the initialization succeeds or fails!