diff --git a/GUIs.Common/Base/BaseErrorHandler.vb b/GUIs.Common/Base/BaseErrorHandler.vb index 87bcae17..1acb2b71 100644 --- a/GUIs.Common/Base/BaseErrorHandler.vb +++ b/GUIs.Common/Base/BaseErrorHandler.vb @@ -14,6 +14,12 @@ Namespace Base _Form = Form End Sub + Public Sub New(pLogConfig As LogConfig, pForm As Form) + _LogConfig = pLogConfig + _Logger = pLogConfig.GetLogger(LogConfig.GetClassFullName()) + _Form = pForm + End Sub + Public Sub ShowErrorMessage(Exception As Exception, Origin As String) Dim oMessage = GetMessage(Exception, Origin) ShowErrorMessage(Exception, Origin, oMessage) diff --git a/GUIs.Common/Common.vbproj b/GUIs.Common/Common.vbproj index 5b0c6db3..5a509861 100644 --- a/GUIs.Common/Common.vbproj +++ b/GUIs.Common/Common.vbproj @@ -121,6 +121,7 @@ + diff --git a/GUIs.Common/IBaseForm.vb b/GUIs.Common/IBaseForm.vb new file mode 100644 index 00000000..d4e0913e --- /dev/null +++ b/GUIs.Common/IBaseForm.vb @@ -0,0 +1,8 @@ +Imports DigitalData.GUIs.Common.Base +Imports DigitalData.Modules.Logging + +Public Interface IBaseForm + ReadOnly Property LogConfig As LogConfig + ReadOnly Property Logger As Logger + ReadOnly Property ErrorHandler As BaseErrorHandler +End Interface