Hi ALex,
You can still use an enum but show a single letter (or a full name) to the user. Our enum BO's just have the following code:
Private Sub boenBatchTypes_ParentFormLoading() Handles Me.ParentFormLoading
Dim ColDesc As String = "Description"
Dim dt As New Data.DataTable
dt = MicroFour.StrataFrame.Tools.Common.BuildDataTableFromEnum(GetType(UtilEnums.clsEnum.BatchTypes))
' Localise Batch names
For i As Integer = 0 To dt.Rows.Count - 1
dt.Rows.Item(i).Item(ColDesc) = UtilLocalisation.clsLocalise.Localise(dt.Rows.Item(i).Item(ColDesc).ToString)
Next
dt.DefaultView.Sort = ColDesc
Me.CopyDataFrom(dt.DefaultView.ToTable, MicroFour.StrataFrame.Business.BusinessCloneDataType.ClearAndFillFromCompleteTable)
dt = Nothing
End Sub
In this example:
.BuildDataTableFromEnum - standard SF function to extract our "batch name" enums and creates a data table
UtilLocalisation.. - is our own function to localise the enum description.
Me.CopyDataFrom - standard SF sub to load the populate the BO.
Easy as and works a treat.
Cheers, Peter