Loupe - Log - Monitor - Resolve
Gibraltar.Agent Namespace / Packager Class / SendToFile Method / SendToFile(SessionCriteria,Boolean,String) Method
The set of match rules to apply to sessions to determine what to send.
True to have every included session marked as read upon successful completion.
The file name and path to write the final package to.
Example

In This Topic
    SendToFile(SessionCriteria,Boolean,String) Method
    In This Topic
    Write the completed package to the provided full file name (without extension) and path. The extension will be set to glp automatically.
    Syntax
    'Declaration
     
    
    Public Overloads Sub SendToFile( _
       ByVal sessions As SessionCriteria, _
       ByVal markAsRead As Boolean, _
       ByVal fullFileNamePath As String _
    ) 

    Parameters

    sessions
    The set of match rules to apply to sessions to determine what to send.
    markAsRead
    True to have every included session marked as read upon successful completion.
    fullFileNamePath
    The file name and path to write the final package to.
    Exceptions
    ExceptionDescription
    Thrown when generation or transmission fails, includes details on failure
    A required parameter was null.
    The provided file information is not a fully qualified file name and path.
    Remarks
    The EndSend event will be raised when the send operation completes. Any provided extension will be removed and replaced with the standard Loupe package extension.
    Example
    //Send a file with all of the information about the current application we haven't sent before.
    using (Packager packager = new Packager())
    {
        //the file name will automatically have the appropriate extension added, so it is specified 
        //below without any file extension.  Typically you will want to generate a unique, temporary
        //file name to store the data as instead of using a fixed file name.
        packager.SendToFile(SessionCriteria.NewSessions, true, "C:\YourAppSessionData");
    }
    Requirements

    Target Platforms: Windows 7, 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