Version

ExportAsync(DataPresenterBase,Stream,Boolean) Method

Asynchronously exports the specified DataPresenter derived control to the specified file.
Syntax
'Declaration
 
Public Overloads Sub ExportAsync( _
   ByVal dataPresenter As DataPresenterBase, _
   ByVal stream As Stream, _
   ByVal closeStream As Boolean _
) 
public void ExportAsync( 
   DataPresenterBase dataPresenter,
   Stream stream,
   bool closeStream
)

Parameters

dataPresenter
The control whose records are to be exported
stream
The stream to which the Word document should be written.
closeStream
A boolean indicating whether the stream should be explicitly closed after the ExportEnding event has been raised.
Exceptions
ExceptionDescription
System.ArgumentNullExceptionThe dataPresenter and stream must be non-null values.
System.InvalidOperationExceptionThe CanWrite of the stream must be true.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also