Imports DevExpress.Utils.Svg Imports DevExpress.XtraBars.Ribbon Public Class Placeholders Public Function GetInternalGroup() As GalleryItemGroup Dim oModule = "INT" Dim oImage = My.Resources.electronics_desktopmac Dim oItems As New List(Of GalleryItem)() From { GetGalleryItem(New Placeholder("USERNAME", "Benutzername", oModule, "USERNAME"), oImage), GetGalleryItem(New Placeholder("MACHINE", "Aktuelles Datum", oModule, "MACHINE"), oImage), GetGalleryItem(New Placeholder("DOMAIN", "Email-Adresse", oModule, "DOMAIN"), oImage), GetGalleryItem(New Placeholder("DATE", "Vorname", oModule, "DATE"), oImage) } Dim oGroup1 = New GalleryItemGroup() With {.Caption = "Intern"} oGroup1.Items.AddRange(oItems.ToArray) Return oGroup1 End Function Public Function GetUserGroup() As GalleryItemGroup Dim oModule = "USER" Dim oImage = My.Resources.actions_user Dim oItems As New List(Of GalleryItem)() From { GetGalleryItem(New Placeholder("PRENAME", "Vorname", oModule, "PRENAME"), oImage), GetGalleryItem(New Placeholder("SURNAME", "Nachname", oModule, "SURNAME"), oImage), GetGalleryItem(New Placeholder("EMAIL", "Email-Adresse", oModule, "EMAIL"), oImage), GetGalleryItem(New Placeholder("USER_ID", "Benutzer-ID", oModule, "USER_ID"), oImage), GetGalleryItem(New Placeholder("PROFILE_ID", "Profil-ID", oModule, "PROFILE_ID"), oImage), GetGalleryItem(New Placeholder("PROFILE_TITLE", "Profil-Name", oModule, "PROFILE_TITLE"), oImage), GetGalleryItem(New Placeholder("LANGUAGE", "Sprache", oModule, "LANGUAGE"), oImage) } Dim oGroup1 = New GalleryItemGroup() With {.Caption = "Benutzer"} oGroup1.Items.AddRange(oItems.ToArray) Return oGroup1 End Function Private Function GetGalleryItem(pPlaceholder As Placeholder) As GalleryItem Return New GalleryItem(Nothing, pPlaceholder.Title, pPlaceholder.Description) With { .Tag = pPlaceholder } End Function Private Function GetGalleryItem(pPlaceholder As Placeholder, pImage As SvgImage) As GalleryItem Dim oItem = New GalleryItem(Nothing, pPlaceholder.Title, pPlaceholder.Description) With { .Tag = pPlaceholder } oItem.ImageOptions.SvgImage = pImage Return oItem End Function End Class