Load Dynamic Form for frmEdit, Save Application Skin, add UIConfig

This commit is contained in:
Jonathan Jenne
2019-02-21 16:53:27 +01:00
parent 08e3ca9dd3
commit 72788c84bd
18 changed files with 366 additions and 94 deletions

View File

@@ -1,4 +1,5 @@
Imports System.IO
Imports DevExpress.XtraGrid.Views.Base
''' <summary>
''' Helper Class to save DevExpress layouts
@@ -17,6 +18,7 @@
Public Class ClassLayout
Public Enum GroupName
LayoutMain
LayoutUserManager
End Enum
Public Enum LayoutComponent
@@ -35,6 +37,29 @@ Public Class ClassLayout
Return Path.Combine(GetLayoutDirectory(), oFileName)
End Function
''' <summary>
''' Returns a path for the chosen Devexpress layout file
''' </summary>
''' <param name="Group">The Group to which the the component belongs to. For example, a form could be a Layout</param>
''' <param name="Component">The component to which the layout belongs to</param>
''' <returns></returns>
Public Shared Function GetLayoutPath(Group As GroupName, Component As String) As String
Dim oFileName As String = $"{Group.ToString}-{Component}.xml"
Return Path.Combine(GetLayoutDirectory(), oFileName)
End Function
''' <summary>
''' Returns a path for the chosen Devexpress layout file
''' </summary>
''' <param name="Group">The Group to which the the component belongs to. For example, a form could be a Layout</param>
''' <param name="Component">The component to which the layout belongs to</param>
''' <param name="SubComponent">The sub component under the component</param>
''' <returns></returns>
Public Shared Function GetLayoutPath(Group As GroupName, Component As String, SubComponent As String) As String
Dim oFileName As String = $"{Group.ToString}-{Component}-{SubComponent}.xml"
Return Path.Combine(GetLayoutDirectory(), oFileName)
End Function
Public Shared Function GetLayoutDirectory() As String
Return Path.Combine(GetAppDataFolder(), ClassConstants.FOLDER_NAME_LAYOUT)
End Function