I am trying to query the EventLogs to determine if they are exceeding 80% of
their maximum file size, but this query doesn't retun any records. Here is
my query string:
Set colItems = objWMIService.ExecQuery("SELECT * FROM Win32_NTEventlogFile
where (FILESIZE > (.80 * MAXFILESIZE)) and filename = 'appevent' ", "WQL", _
wbemFlagReturnImmediately + wbemFlagForwardOnly)
If I change the compare operand to "<=", it doesn't return any records
either. SO, I assume that the querystring doesn't like the (.80 *) muliplier
in the query.
As of now, my work around is to return all records and use an If...then to
determine if the FILESIZE is 80% of the MAXFILESIZE.
...just trying to cut corners! My guess is that the type cast for the
FILESIZE and MAXFILESIZE is character - not number?? ...any clues?
PS...I have debugged the "numbers" - the querystring is logically correct
and should return a record set.
--
-Kevin