Skip to main content

Logging

Two types of logs are defined by a QvxLogFacility flag and four levels of log messages are defined by a QvxLogSeverity flag. When creating a log post, you must always (besides the message itself) set a facility and a severity for the message. For example:

QvxLog.Log(QvxLogFacility.Application, QvxLogSeverity.Notice, "Init()");

The different facilities and severity levels are all documented in the DLL.

It is also possible to decide which messages are actually added to the log. Tthat is, during normal runtime you are most likely not interested in getting all debug messages, and maybe not even warnings. Use QvxLog.SetLogLevels() to switch warning and debug messages on and off:

QvxLog.SetLogLevels(bool LogDebug, bool logWarning);

Messages with severity Notice or Error are always included in the log.

The log files are saved in C:\ProgramData\QlikTech\Custom Data\{The name of the Connector}\Log. The log files can be imported into QlikView or Qlik Sense for further analysis. The following example script loads a log file generated by a connector into QlikView:

LOAD *

FROM

[C:\ProgramData\QlikTech\Custom Data\QvFacebookConnector\Log\2012-03-29QvxApplication.log]

(txt, codepage is 1252, embedded labels, delimiter is '\t', msq);

 

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – let us know how we can improve!