TraceFlags Property  
 

Gets and sets the socket function tracing flags.

Syntax

object.TraceFlags [= traceflags ]

Remarks

The TraceFlags property is used to specify the type of information written to the trace file when socket function tracing is enabled. The following values may be used:

Value Constant Description
0 dnsTraceInfo All function calls are written to the trace file, including information about successful calls made to the networking library. This is the default value.
1 dnsTraceError Only those function calls which fail are recorded in the trace file. Functions which are successful or only return values which indicate a warning are not logged.
2 dnsTraceWarning Only those function calls which fail, or return values which indicate a warning, are recorded in the trace file. Successful function calls are not logged.
4 dnsTraceHexDump All functions calls are written to the trace file, plus all the data that is sent or received is displayed in both ASCII and hexadecimal format. This is useful for examining the actual byte stream that is exchanged between the application and the remote host.

Since function logging is enabled per-process, the trace flags are shared by all instances of the controls being used. If multiple controls have tracing enabled, the TraceFlags property should be set to the same value for each control. Changing the trace flags for any one instance of the control will affect the logging performed for all controls used by the application.

Warnings are generated when a non-fatal error is returned by a Windows Sockets function. For example, if data is being written through the control and an error indicating that the operation would block is returned, only a warning is logged since the application simply needs to attempt to write the data at a later time.

Data Type

Integer (Int32)

See Also

Trace Property, TraceFile Property