I'm trying to pass a Telerik CrystalPalette to a Sub but I get an error "...is class type and can not be used as an expression". Hints?
Public Function DoSomething() As Boolean
ApplyThemeFontSizes(CrystalTheme)
End Function
Private Sub ApplyThemeFontSizes(Of T)()
Try
T.Palette.FontSizeXS = 8 + Me.FontOffset
T.Palette.FontSizeS = 10 + Me.FontOffset
T.Palette.FontSize = 12 + Me.FontOffset
T.Palette.FontSizeL = 14 + Me.FontOffset
T.Palette.FontSizeXL = 16 + Me.FontOffset
Catch ex As Exception
' TODO: Log error to file (possible the Theme doesn't have a "Palette")
End Try
End Sub