The recording of the first ever ReactiveUI virtual conference is available on our YouTube Channel.


Observable.ToEvent<TSource> Method (IObservable<TSource>)

Exposes an observable sequence as an object with a .NET event with a specified source.

Namespace:  System.Reactive.Linq
Assembly:  System.Reactive (in System.Reactive.dll)


<ExtensionAttribute> _
Public Shared Function ToEvent(Of TSource) ( _
    source As IObservable(Of TSource) _
) As IEventSource(Of TSource)
Dim source As IObservable(Of TSource)
Dim returnValue As IEventSource(Of TSource)

returnValue = source.ToEvent()
public static IEventSource<TSource> ToEvent<TSource>(
    this IObservable<TSource> source
generic<typename TSource>
static IEventSource<TSource>^ ToEvent(
    IObservable<TSource>^ source
static member ToEvent : 
        source:IObservable<'TSource> -> IEventSource<'TSource> 
JScript does not support generic types and methods.

Type Parameters

  • TSource
    The type of source


Return Value

Type: System.Reactive.IEventSource<TSource>
The event source object.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IObservable<TSource>. When you use instance method syntax to call this method, omit the first parameter. For more information, see or .

See Also


Observable Class

ToEvent Overload

System.Reactive.Linq Namespace