> >Private decPeriodDay1 As Decimal = Nothing > Private decPeriodDay2 As Decimal = Nothing > Private decPeriodDay3 As Decimal = Nothing >..... > > Private decPeriodDay363 As Decimal = Nothing > Private decPeriodDay364 As Decimal = Nothing > Private decPeriodDay365 As Decimal = Nothing > Private decPeriodDay366 As Decimal = Nothing >>and then declare a property 366 times.
>Public Property PeriodDay1() As Decimal > Get > Return decPeriodDay1 > End Get > Set(ByVal value As Decimal) > decPeriodDay1 = value > End Set > End Property > >..... > > Public Property PeriodDay366() As Decimal > Get > Return decPeriodDay366 > End Get > Set(ByVal value As Decimal) > decPeriodDay366 = value > End Set > End Property >>All this information in a class. If somebody know a better approach I will apreaciate.
Class PeriodDays Private Days As Decimal() = New Decimal(365) {} Public Function GetDay(i As Integer) As Decimal Return Days(i - 1) End Function Public Sub SetDay(i As Integer, d As Decimal) Days(i - 1) = d End Sub End ClassDefault values would be zero, might need some code to handle out of bounds exceptions as well.....