jj: Update TesTGUI & EDM Designer
This commit is contained in:
@@ -6,7 +6,7 @@ Public Class FrmMain
|
||||
Private _selectedTable As Integer
|
||||
Private _selectedTableName As String
|
||||
|
||||
Private _logger As NLog.Logger
|
||||
Private _logger As Logger
|
||||
Private _logConfig As LogConfig
|
||||
Private _firebird As Firebird
|
||||
|
||||
@@ -56,7 +56,7 @@ Public Class FrmMain
|
||||
End Function
|
||||
|
||||
Private Sub Init()
|
||||
_firebird = New Firebird(_logConfig.LogFactory, My.Settings.fbDatasource, My.Settings.fbDatabaseLocation, My.Settings.fbUser, My.Settings.fbPassword)
|
||||
_firebird = New Firebird(_logConfig, My.Settings.fbDatasource, My.Settings.fbDatabaseLocation, My.Settings.fbUser, My.Settings.fbPassword)
|
||||
|
||||
If _firebird.ConnectionFailed Then
|
||||
MsgBox("Database connection failed. Please check the log.", vbCritical)
|
||||
@@ -72,13 +72,25 @@ Public Class FrmMain
|
||||
End Sub
|
||||
|
||||
Private Sub FrmMain_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
_logConfig = New LogConfig(ClassLogger.PathType.CurrentDirectory)
|
||||
_logger = _logConfig.LogFactory.GetCurrentClassLogger()
|
||||
_logConfig = New LogConfig(LogConfig.PathType.CurrentDirectory)
|
||||
_logger = _logConfig.GetLogger() '_logConfig.LogFactory.GetCurrentClassLogger(GetType(Logger))
|
||||
|
||||
_logger.NewBlock("STARTUP")
|
||||
_logger.Info("INFO")
|
||||
_logger.Warn("WARN")
|
||||
_logger.NewBlock("ERROR")
|
||||
|
||||
|
||||
Try
|
||||
Throw New Exception("ERROR")
|
||||
Catch ex As Exception
|
||||
_logger.Error(ex)
|
||||
End Try
|
||||
|
||||
' Check for existing database credentials
|
||||
While Not DatabaseSettingsExist()
|
||||
Dim form As New FrmConnection With {
|
||||
.LogFactory = _logConfig.LogFactory
|
||||
.LogConfig = _logConfig
|
||||
}
|
||||
Dim result As DialogResult = form.ShowDialog()
|
||||
|
||||
@@ -151,7 +163,7 @@ Public Class FrmMain
|
||||
End Sub
|
||||
|
||||
Private Sub NeueTabelleToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles NeueTabelleToolStripMenuItem.Click
|
||||
Dim oForm As New FrmNewTable(_logConfig.LogFactory)
|
||||
Dim oForm As New FrmNewTable(_logConfig)
|
||||
oForm.ShowDialog()
|
||||
|
||||
Dim oTables As DataTable = LoadTables()
|
||||
|
||||
Reference in New Issue
Block a user