Using Win32 functions in Visual FoxPro Image Gallery
Event Logging
..msdn
ClearEventLog
CloseEventLog
DeregisterEventSource
GetEventLogInformation
GetNumberOfEventLogRecords
GetOldestEventLogRecord
OpenEventLog
ReadEventLog
RegisterEventSource
ReportEvent
Code examples:
Reading entries from Event logs
ClearEventLog
..msdn    Add comment     W32 Constants      Translate this page
Clears the specified event log, and optionally saves the current copy of the log to a backup file.
Code examples:
Reading entries from Event logs
Declaration:
BOOL ClearEventLog(
  HANDLE hEventLog,
  LPCTSTR lpBackupFileName
);
FoxPro declaration:
DECLARE INTEGER ClearEventLog IN advapi32;
    INTEGER hEventLog,;
    STRING lpBackupFileName
Parameters:
hEventLog
[in] A handle to the event log to be cleared. This handle is returned by the OpenEventLog function.

lpBackupFileName
[in] The name of the backup file. If this file already exists, the function fails.
If the lpBackupFileName parameter is NULL, the current event log is not backed up.

Return value:
If the function succeeds, the return value is nonzero.
My comment:
The ClearEventLog function fails if the event log is empty or a file already exists with the same name as lpBackupFileName.

After this function returns, any handles that reference the cleared event log cannot be used to read the log.
Word Index links for the ClearEventLog :
Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
Created: 2007-09-09 20:20:46
Modified: 2007-09-09 20:25:08
Visited in last 7 days: 13
User Contributed Notes:
There are no notes on this subject.


Copyright 2001-2017 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

Privacy policy
Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.6.37), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
Last Topics Visited (107.22.126.144)
10 sec.Examples
23 sec.Function: 'ConfigurePort'
35 sec.Function: 'CeRapiGetError'
47 sec.
Function group: 'Remote Access Service (RAS)'
58 sec.
Function group: 'Clipboard'
1.15 min.Function: 'GetBkMode'
1.37 min.Function: 'CryptBinaryToString'
1.57 min.Function: 'GetDlgItem'
1.77 min.Function: 'FileIconInit'
1.98 min.Function: 'CeMoveFile'
Google
Advertise here!