AR Log ActiveX Library 2.0

This library will allow you to add logging capabilities to your applications. You will also be able to: erase events ocurred to an specific date; erase events till the log has the size you want; list events ocurred after a date, till a date or both; use priorities for events; have the information stored encrypted.

History:

Properties:

To get the number of events saved in the log file:
Print Log.List(All).Count

To get a collection with all the events with 'high' priority ocurred between March 24th and March 26th, 1998:
Dim MyCol As New Collection
Set MyCol = Log.List(HighEx, CDate(#3/24/98#), CDate(#3/26/98#))
(The date format may vary depending on your regional configuration)

To print all the events with their dates from this collection:
Dim N As Long
For N = 1 To MyCol.Count
Print MyCol(N).dDate & Chr(9) & MyCol(N).sEvent
Next N

Methods:

Enumerations:

This library uses two different enumerations, which enumPriority and enumPriorityEx. You use the first one when you are adding an event, or when you are consulting the objects in the collections that you receive after a search. You use the second one when you are doing a search.

Low = 0
Normal = 1
High = 2

LowEx = 0
NormalEx = 1
HighEx = 2
All = 3

The object clsRec:

This is a class with three public properties:

Error constants:

The error constants that this library will put in the 'LastError' property are the following:

AR_NO_ERROR = &H0
AR_NO_FILE_SPECIFIED = &H1
AR_ERROR_IN_FILE = &H2
AR_LIBRARY_IS_LOCKED = &H3
AR_FILE_IS_EMPTY = &H4
AR_UNKNOWN_ERROR = &H5
AR_NO_SIZE_SPECIFIED = &H6

Check these constants against the 'LastError' property to know about the last error that the library produced. You can also use the 'LastErrorDescription' property to show a description about the last error.

 

(18 Kb)

© Alvaro Redondo, 1998. All Rights Reserved.
http://www.sevillaonline.com/ActiveX/