IndexOf Method

TraceListenerCollection.IndexOf Method

Gets the index of the specified listener.

[Visual Basic]
Public Function IndexOf( _
   ByVal listener As TraceListener _
) As Integer
[C#]
public int IndexOf(
 TraceListener listener
);
[C++]
public: int IndexOf(
 TraceListener* listener
);
[JScript]
public function IndexOf(
   listener : TraceListener
) : int;

Parameters

listener
A TraceListener to find in the list.

Return Value

The index of the listener, if it can be found in the list; otherwise, -1.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework

See Also

TraceListenerCollection Class | TraceListenerCollection Members | System.Diagnostics Namespace | TraceListenerCollection | TraceListener | DefaultTraceListener | TextWriterTraceListener | Debug | Trace

Show:
© 2016 Microsoft