>oApp.Labels("Company").Title_E >oApp.Labels("Company").Title_F >>
>oApp.Labels("Company").Title
>
>> ' Label class > Public Class Label > Private cName As String = "" > Private cTitle As String = "" > Private cTitle_E As String = "" > Private cTitle_F As String = "" > Private cTitle_S As String = "" > Private cTitle_P As String = "" > > ' expC1 Name > ' expC2 Title in English > ' expC3 Title in French > ' expC4 Title in Spanish > ' expC5 Title in Portuguese > Public Sub New(ByVal tcName As String, ByVal tcTitle_E As String, _ > ByVal tcTitle_F As String, ByVal tcTitle_S As String, _ > ByVal tcTitle_P As String) > > cName = tcName > cTitle_E = tcTitle_E > cTitle_F = tcTitle_F > cTitle_S = tcTitle_S > cTitle_P = tcTitle_P > > End Sub > > Public ReadOnly Property Name As String > Get > Return cName > End Get > End Property > > Public ReadOnly Property Title As String > Get > Dim lcTitle As String = "" > Dim lnLanguage As Integer = 0 > > ' In the following line, I need to find a way to have oApp available here so I can get > ' the nLanguage property value and return the title of the label based on it. > > ' lnLanguage = oApp.nLanguage > > ' Based on the language > Select Case lnLanguage > > ' English > Case 1 > lcTitle = Title_E > > ' French > Case 2 > lcTitle = Title_F > > ' Spanish > Case 3 > lcTitle = Title_S > > ' Portuguese > Case 4 > lcTitle = Title_P > > End Select > > Return lcTitle > End Get > End Property > > Public ReadOnly Property Title_E As String > Get > Return cTitle_E > End Get > End Property > > Public ReadOnly Property Title_F As String > Get > Return cTitle_F > End Get > End Property > > Public ReadOnly Property Title_S As String > Get > Return cTitle_S > End Get > End Property > > Public ReadOnly Property Title_P As String > Get > Return cTitle_P > End Get > End Property > > End Class > > Public Class Labels > Inherits System.Collections.Specialized.NameObjectCollectionBase > > Public Overloads Sub Add(ByVal Label As Label) > BaseAdd(Label.Name, Label) > End Sub > > Default Public Overloads ReadOnly Property Item(ByVal Title As String) As Label > Get > Return CType(BaseGet(Title), Label) > End Get > End Property > > End Class >>