diff --git a/GUIs.Monitor/My Project/AssemblyInfo.vb b/GUIs.Monitor/My Project/AssemblyInfo.vb index 330d72a8..a0dbde7f 100644 --- a/GUIs.Monitor/My Project/AssemblyInfo.vb +++ b/GUIs.Monitor/My Project/AssemblyInfo.vb @@ -8,7 +8,7 @@ Imports System.Runtime.InteropServices - + diff --git a/GUIs.Monitor/frmStart.Designer.vb b/GUIs.Monitor/frmStart.Designer.vb index 5b64e996..f48105bd 100644 --- a/GUIs.Monitor/frmStart.Designer.vb +++ b/GUIs.Monitor/frmStart.Designer.vb @@ -27,7 +27,7 @@ Partial Class frmStart Private Sub InitializeComponent() Me.components = New System.ComponentModel.Container() Me.RibbonControl1 = New DevExpress.XtraBars.Ribbon.RibbonControl() - Me.BarButtonItem1 = New DevExpress.XtraBars.BarButtonItem() + Me.buttonSearch = New DevExpress.XtraBars.BarButtonItem() Me.RibbonPage1 = New DevExpress.XtraBars.Ribbon.RibbonPage() Me.RibbonPageGroup1 = New DevExpress.XtraBars.Ribbon.RibbonPageGroup() Me.RibbonStatusBar1 = New DevExpress.XtraBars.Ribbon.RibbonStatusBar() @@ -45,9 +45,12 @@ Partial Class frmStart Me.LayoutControlItem3 = New DevExpress.XtraLayout.LayoutControlItem() Me.DockPanel2 = New DevExpress.XtraBars.Docking.DockPanel() Me.DockPanel2_Container = New DevExpress.XtraBars.Docking.ControlContainer() + Me.XtraTabControl1 = New DevExpress.XtraTab.XtraTabControl() + Me.XtraTabPage1 = New DevExpress.XtraTab.XtraTabPage() Me.GridControl1 = New DevExpress.XtraGrid.GridControl() Me.GridView1 = New DevExpress.XtraGrid.Views.Grid.GridView() - Me.TreeList1 = New DevExpress.XtraTreeList.TreeList() + Me.XtraTabPage2 = New DevExpress.XtraTab.XtraTabPage() + Me.TreeListResults = New DevExpress.XtraTreeList.TreeList() CType(Me.RibbonControl1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.DockManager1, System.ComponentModel.ISupportInitialize).BeginInit() Me.DockPanel1.SuspendLayout() @@ -63,28 +66,31 @@ Partial Class frmStart CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).BeginInit() Me.DockPanel2.SuspendLayout() Me.DockPanel2_Container.SuspendLayout() + CType(Me.XtraTabControl1, System.ComponentModel.ISupportInitialize).BeginInit() + Me.XtraTabControl1.SuspendLayout() + Me.XtraTabPage1.SuspendLayout() CType(Me.GridControl1, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.GridView1, System.ComponentModel.ISupportInitialize).BeginInit() - CType(Me.TreeList1, System.ComponentModel.ISupportInitialize).BeginInit() + CType(Me.TreeListResults, System.ComponentModel.ISupportInitialize).BeginInit() Me.SuspendLayout() ' 'RibbonControl1 ' Me.RibbonControl1.ExpandCollapseItem.Id = 0 - Me.RibbonControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl1.ExpandCollapseItem, Me.RibbonControl1.SearchEditItem, Me.BarButtonItem1}) + Me.RibbonControl1.Items.AddRange(New DevExpress.XtraBars.BarItem() {Me.RibbonControl1.ExpandCollapseItem, Me.RibbonControl1.SearchEditItem, Me.buttonSearch}) Me.RibbonControl1.Location = New System.Drawing.Point(0, 0) Me.RibbonControl1.MaxItemId = 2 Me.RibbonControl1.Name = "RibbonControl1" Me.RibbonControl1.Pages.AddRange(New DevExpress.XtraBars.Ribbon.RibbonPage() {Me.RibbonPage1}) - Me.RibbonControl1.Size = New System.Drawing.Size(1085, 158) + Me.RibbonControl1.Size = New System.Drawing.Size(1085, 159) Me.RibbonControl1.StatusBar = Me.RibbonStatusBar1 ' - 'BarButtonItem1 + 'buttonSearch ' - Me.BarButtonItem1.Caption = "Suchen" - Me.BarButtonItem1.Id = 1 - Me.BarButtonItem1.ImageOptions.SvgImage = Global.DigitalData.GUIs.Monitor.My.Resources.Resources.gettingstarted - Me.BarButtonItem1.Name = "BarButtonItem1" + Me.buttonSearch.Caption = "Suchen" + Me.buttonSearch.Id = 1 + Me.buttonSearch.ImageOptions.SvgImage = Global.DigitalData.GUIs.Monitor.My.Resources.Resources.gettingstarted + Me.buttonSearch.Name = "buttonSearch" ' 'RibbonPage1 ' @@ -94,16 +100,16 @@ Partial Class frmStart ' 'RibbonPageGroup1 ' - Me.RibbonPageGroup1.ItemLinks.Add(Me.BarButtonItem1) + Me.RibbonPageGroup1.ItemLinks.Add(Me.buttonSearch) Me.RibbonPageGroup1.Name = "RibbonPageGroup1" Me.RibbonPageGroup1.Text = "RibbonPageGroup1" ' 'RibbonStatusBar1 ' - Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 652) + Me.RibbonStatusBar1.Location = New System.Drawing.Point(0, 654) Me.RibbonStatusBar1.Name = "RibbonStatusBar1" Me.RibbonStatusBar1.Ribbon = Me.RibbonControl1 - Me.RibbonStatusBar1.Size = New System.Drawing.Size(1085, 24) + Me.RibbonStatusBar1.Size = New System.Drawing.Size(1085, 22) ' 'RibbonPage2 ' @@ -121,20 +127,20 @@ Partial Class frmStart Me.DockPanel1.Controls.Add(Me.DockPanel1_Container) Me.DockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Left Me.DockPanel1.ID = New System.Guid("52706dba-4c71-4145-b8a3-5f5423d32fce") - Me.DockPanel1.Location = New System.Drawing.Point(0, 158) + Me.DockPanel1.Location = New System.Drawing.Point(0, 159) Me.DockPanel1.Name = "DockPanel1" Me.DockPanel1.Options.ShowCloseButton = False Me.DockPanel1.Options.ShowMaximizeButton = False Me.DockPanel1.OriginalSize = New System.Drawing.Size(200, 200) - Me.DockPanel1.Size = New System.Drawing.Size(200, 494) + Me.DockPanel1.Size = New System.Drawing.Size(200, 495) Me.DockPanel1.Text = "Suche" ' 'DockPanel1_Container ' Me.DockPanel1_Container.Controls.Add(Me.LayoutControl1) - Me.DockPanel1_Container.Location = New System.Drawing.Point(3, 26) + Me.DockPanel1_Container.Location = New System.Drawing.Point(3, 46) Me.DockPanel1_Container.Name = "DockPanel1_Container" - Me.DockPanel1_Container.Size = New System.Drawing.Size(193, 465) + Me.DockPanel1_Container.Size = New System.Drawing.Size(193, 446) Me.DockPanel1_Container.TabIndex = 0 ' 'LayoutControl1 @@ -146,7 +152,7 @@ Partial Class frmStart Me.LayoutControl1.Location = New System.Drawing.Point(0, 0) Me.LayoutControl1.Name = "LayoutControl1" Me.LayoutControl1.Root = Me.Root - Me.LayoutControl1.Size = New System.Drawing.Size(193, 465) + Me.LayoutControl1.Size = New System.Drawing.Size(193, 446) Me.LayoutControl1.TabIndex = 0 Me.LayoutControl1.Text = "LayoutControl1" ' @@ -185,7 +191,7 @@ Partial Class frmStart Me.Root.GroupBordersVisible = False Me.Root.Items.AddRange(New DevExpress.XtraLayout.BaseLayoutItem() {Me.LayoutControlItem1, Me.LayoutControlItem2, Me.LayoutControlItem3}) Me.Root.Name = "Root" - Me.Root.Size = New System.Drawing.Size(193, 465) + Me.Root.Size = New System.Drawing.Size(193, 446) Me.Root.TextVisible = False ' 'LayoutControlItem1 @@ -194,10 +200,10 @@ Partial Class frmStart Me.LayoutControlItem1.Location = New System.Drawing.Point(0, 92) Me.LayoutControlItem1.Name = "LayoutControlItem1" Me.LayoutControlItem1.Padding = New DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5) - Me.LayoutControlItem1.Size = New System.Drawing.Size(173, 353) + Me.LayoutControlItem1.Size = New System.Drawing.Size(173, 334) Me.LayoutControlItem1.Text = "Suchwert" Me.LayoutControlItem1.TextLocation = DevExpress.Utils.Locations.Top - Me.LayoutControlItem1.TextSize = New System.Drawing.Size(58, 13) + Me.LayoutControlItem1.TextSize = New System.Drawing.Size(63, 13) ' 'LayoutControlItem2 ' @@ -208,7 +214,7 @@ Partial Class frmStart Me.LayoutControlItem2.Size = New System.Drawing.Size(173, 46) Me.LayoutControlItem2.Text = "Attribut" Me.LayoutControlItem2.TextLocation = DevExpress.Utils.Locations.Top - Me.LayoutControlItem2.TextSize = New System.Drawing.Size(58, 13) + Me.LayoutControlItem2.TextSize = New System.Drawing.Size(63, 13) ' 'LayoutControlItem3 ' @@ -219,29 +225,46 @@ Partial Class frmStart Me.LayoutControlItem3.Size = New System.Drawing.Size(173, 46) Me.LayoutControlItem3.Text = "Auswertung" Me.LayoutControlItem3.TextLocation = DevExpress.Utils.Locations.Top - Me.LayoutControlItem3.TextSize = New System.Drawing.Size(58, 13) + Me.LayoutControlItem3.TextSize = New System.Drawing.Size(63, 13) ' 'DockPanel2 ' Me.DockPanel2.Controls.Add(Me.DockPanel2_Container) Me.DockPanel2.Dock = DevExpress.XtraBars.Docking.DockingStyle.Right Me.DockPanel2.ID = New System.Guid("157c74a2-d255-4e6b-b789-bde43010b2af") - Me.DockPanel2.Location = New System.Drawing.Point(885, 158) + Me.DockPanel2.Location = New System.Drawing.Point(633, 159) Me.DockPanel2.Name = "DockPanel2" Me.DockPanel2.Options.ShowCloseButton = False Me.DockPanel2.Options.ShowMaximizeButton = False - Me.DockPanel2.OriginalSize = New System.Drawing.Size(200, 200) - Me.DockPanel2.Size = New System.Drawing.Size(200, 494) + Me.DockPanel2.OriginalSize = New System.Drawing.Size(452, 200) + Me.DockPanel2.Size = New System.Drawing.Size(452, 495) Me.DockPanel2.Text = "Details" ' 'DockPanel2_Container ' - Me.DockPanel2_Container.Controls.Add(Me.GridControl1) - Me.DockPanel2_Container.Location = New System.Drawing.Point(4, 26) + Me.DockPanel2_Container.Controls.Add(Me.XtraTabControl1) + Me.DockPanel2_Container.Location = New System.Drawing.Point(4, 46) Me.DockPanel2_Container.Name = "DockPanel2_Container" - Me.DockPanel2_Container.Size = New System.Drawing.Size(193, 465) + Me.DockPanel2_Container.Size = New System.Drawing.Size(445, 446) Me.DockPanel2_Container.TabIndex = 0 ' + 'XtraTabControl1 + ' + Me.XtraTabControl1.Dock = System.Windows.Forms.DockStyle.Fill + Me.XtraTabControl1.Location = New System.Drawing.Point(0, 0) + Me.XtraTabControl1.Name = "XtraTabControl1" + Me.XtraTabControl1.SelectedTabPage = Me.XtraTabPage1 + Me.XtraTabControl1.Size = New System.Drawing.Size(445, 446) + Me.XtraTabControl1.TabIndex = 1 + Me.XtraTabControl1.TabPages.AddRange(New DevExpress.XtraTab.XtraTabPage() {Me.XtraTabPage1, Me.XtraTabPage2}) + ' + 'XtraTabPage1 + ' + Me.XtraTabPage1.Controls.Add(Me.GridControl1) + Me.XtraTabPage1.Name = "XtraTabPage1" + Me.XtraTabPage1.Size = New System.Drawing.Size(443, 423) + Me.XtraTabPage1.Text = "XtraTabPage1" + ' 'GridControl1 ' Me.GridControl1.Dock = System.Windows.Forms.DockStyle.Fill @@ -249,7 +272,7 @@ Partial Class frmStart Me.GridControl1.MainView = Me.GridView1 Me.GridControl1.MenuManager = Me.RibbonControl1 Me.GridControl1.Name = "GridControl1" - Me.GridControl1.Size = New System.Drawing.Size(193, 465) + Me.GridControl1.Size = New System.Drawing.Size(443, 423) Me.GridControl1.TabIndex = 0 Me.GridControl1.ViewCollection.AddRange(New DevExpress.XtraGrid.Views.Base.BaseView() {Me.GridView1}) ' @@ -258,21 +281,27 @@ Partial Class frmStart Me.GridView1.GridControl = Me.GridControl1 Me.GridView1.Name = "GridView1" ' - 'TreeList1 + 'XtraTabPage2 ' - Me.TreeList1.Dock = System.Windows.Forms.DockStyle.Fill - Me.TreeList1.Location = New System.Drawing.Point(200, 158) - Me.TreeList1.MenuManager = Me.RibbonControl1 - Me.TreeList1.Name = "TreeList1" - Me.TreeList1.Size = New System.Drawing.Size(685, 494) - Me.TreeList1.TabIndex = 4 + Me.XtraTabPage2.Name = "XtraTabPage2" + Me.XtraTabPage2.Size = New System.Drawing.Size(443, 423) + Me.XtraTabPage2.Text = "XtraTabPage2" + ' + 'TreeListResults + ' + Me.TreeListResults.Dock = System.Windows.Forms.DockStyle.Fill + Me.TreeListResults.Location = New System.Drawing.Point(200, 159) + Me.TreeListResults.MenuManager = Me.RibbonControl1 + Me.TreeListResults.Name = "TreeListResults" + Me.TreeListResults.Size = New System.Drawing.Size(433, 495) + Me.TreeListResults.TabIndex = 4 ' 'frmStart ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font Me.ClientSize = New System.Drawing.Size(1085, 676) - Me.Controls.Add(Me.TreeList1) + Me.Controls.Add(Me.TreeListResults) Me.Controls.Add(Me.DockPanel2) Me.Controls.Add(Me.DockPanel1) Me.Controls.Add(Me.RibbonStatusBar1) @@ -297,9 +326,12 @@ Partial Class frmStart CType(Me.LayoutControlItem3, System.ComponentModel.ISupportInitialize).EndInit() Me.DockPanel2.ResumeLayout(False) Me.DockPanel2_Container.ResumeLayout(False) + CType(Me.XtraTabControl1, System.ComponentModel.ISupportInitialize).EndInit() + Me.XtraTabControl1.ResumeLayout(False) + Me.XtraTabPage1.ResumeLayout(False) CType(Me.GridControl1, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.GridView1, System.ComponentModel.ISupportInitialize).EndInit() - CType(Me.TreeList1, System.ComponentModel.ISupportInitialize).EndInit() + CType(Me.TreeListResults, System.ComponentModel.ISupportInitialize).EndInit() Me.ResumeLayout(False) Me.PerformLayout() @@ -320,11 +352,14 @@ Partial Class frmStart Friend WithEvents LayoutControlItem1 As DevExpress.XtraLayout.LayoutControlItem Friend WithEvents LayoutControlItem2 As DevExpress.XtraLayout.LayoutControlItem Friend WithEvents LayoutControlItem3 As DevExpress.XtraLayout.LayoutControlItem - Friend WithEvents BarButtonItem1 As DevExpress.XtraBars.BarButtonItem + Friend WithEvents buttonSearch As DevExpress.XtraBars.BarButtonItem Friend WithEvents TextEdit2 As DevExpress.XtraEditors.ComboBoxEdit Friend WithEvents DockPanel2 As DevExpress.XtraBars.Docking.DockPanel Friend WithEvents DockPanel2_Container As DevExpress.XtraBars.Docking.ControlContainer - Friend WithEvents TreeList1 As DevExpress.XtraTreeList.TreeList + Friend WithEvents TreeListResults As DevExpress.XtraTreeList.TreeList Friend WithEvents GridControl1 As DevExpress.XtraGrid.GridControl Friend WithEvents GridView1 As DevExpress.XtraGrid.Views.Grid.GridView + Friend WithEvents XtraTabControl1 As DevExpress.XtraTab.XtraTabControl + Friend WithEvents XtraTabPage1 As DevExpress.XtraTab.XtraTabPage + Friend WithEvents XtraTabPage2 As DevExpress.XtraTab.XtraTabPage End Class diff --git a/GUIs.Monitor/frmStart.vb b/GUIs.Monitor/frmStart.vb index 042e7fb5..0592924d 100644 --- a/GUIs.Monitor/frmStart.vb +++ b/GUIs.Monitor/frmStart.vb @@ -12,6 +12,7 @@ Public Class frmStart Try LogConfig = New LogConfig(LogConfig.PathType.AppData, Nothing, Nothing, "Digital Data", "Monitor") ConfigManager = New ConfigManager(Of Config)(LogConfig, Application.UserAppDataPath) + Init(LogConfig) If ConfigManager.Config.ConnectionString = String.Empty Then Dim oSQLConfig As New frmSQLConfig(LogConfig) @@ -26,8 +27,35 @@ Public Class frmStart End If Database = New MSSQLServer(LogConfig, ConfigManager.Config.ConnectionString) + + + Catch ex As Exception ShowErrorMessage(ex) End Try End Sub + + Private Sub buttonSearch_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles buttonSearch.ItemClick + InitTreeList() + LoadData() + End Sub + + Private Function LoadData() As Boolean + Try + Dim oSQL As String = "EXEC PRDD_MONITORING_GET_TREEVIEW_RESULT 'TYPE1','sdsdd',2" + Dim oTable As DataTable = Database.GetDatatable(oSQL) + + TreeListResults.DataSource = oTable + + Return True + Catch ex As Exception + ShowErrorMessage(ex) + Return False + End Try + End Function + + Private Sub InitTreeList() + TreeListResults.KeyFieldName = "GUID" + TreeListResults.ParentFieldName = "PARENT_ID" + End Sub End Class \ No newline at end of file