Calculates an Adler32 checksum for a file.
varCRC = CRCControlObject.Adler32File(Filename, HexYN, [MaxChunkSize], [FileNum])The Adler32File Method has the following parts:
Part Description Filename Required. String containing path and filename. HexYN Required. Boolean value. True if the CRC should be returned as a Hex string, False if it should be returned as a Long integer. MaxChunkSize Optional. Double (8 byte) integer. Specifies the maximum number of bytes to read from the file in each chunk. If this argument is missing, the CRC toolkit calculates a MaxChunkSize value based on the value of the RAMPercentToUse Property. Argument value must be 0 (the default value, meaning argument is to be ignored) or >= 1024. For obvious reasons (VB file operations and the number of elements in an array both being limited to Long values), a value of > 2147483647 is invalid. A value of > 2147483647 will be silently reduced to 2147483647 without the raising of an error.
This argument has no affect on the actual CRC calculated, it is concerned only with the efficient use of system memory.
FileNum Optional. Long integer. If the target file has already been opened by your application for binary access, you may pass the VB file handle. If this argument is missing, the method will open the file and close it before exiting. Value must be in the range 0 to 511, where 0 (the default) means you are not passing a file handle.