view Glimpse/Glimpse Controls/LoadExceptionViewer.xaml.vb @ 82:352ecaa4fcfd

remove sharpnel
author Steven Hollidge <stevenhollidge@hotmail.com>
date Mon, 23 Apr 2012 23:20:21 +0100
parents 3591c26bd63e
children
line wrap: on
line source

Partial Public Class LoadExceptionViewer
    Inherits UserControl

    Public Sub New()
        InitializeComponent()
    End Sub

    Public Sub New(ByVal e As Exception, ByVal strSourceLocation As String)
        InitializeComponent()
        Me.txtSourceLocation.Text = String.Concat("Source Location: ", strSourceLocation)

        Dim ex As Exception = e

        While ex IsNot Nothing
            Me.lbExceptions.Items.Add(ex)
            ex = ex.InnerException
        End While

        If Me.lbExceptions.Items.Count > 0 Then
            Me.lbExceptions.SelectedIndex = 0
        End If

    End Sub

End Class