To many people, including Ron Owens, the word "some" refers to a relatively small amount in between "none" and "most". But To Ron's employer, and especially in the context of "job responsibly include... some maintenance of legacy VB6 applications", the word "some" tends to mean "pretty much all day long for the indefinite future."

Because legacy application maintenance is one of the torments found in the outer circles of hell, Ron had hoped to find catharsis by sending in examples of his day-to-day. But alas, because the application was so large and had been maintained by so many people, there was no single, concise snippet that faithfully represented what he was dealing with. That is, until recently, where he uncovered a snippet that not only illustrated the (over)complexity of the application but offers glimpse into what the UI looks like.

For Each LVRefWarnItem In Me.ListViewRefWarn.ListItems
  For Each LVDiagItem In Me.ListViewDiag.ListItems
    For Each LVReqdClassItem In Me.ListViewReqdClass.ListItems
      For Each LVReqdPayItem In Me.ListViewReqdPay.ListItems
        For Each LVReqdSpecItem In Me.ListViewReqdSpec.ListItems
          For Each LVReqingSpecItem In Me.ListViewReqingSpec.ListItems
            For Each LVSvcItem In Me.ListViewSvc.ListItems
              For Each LVReqdContItem In Me.ListViewReqdCont.ListItems
                For Each LVReqingContItem In Me.ListViewReqingCont.ListItems
                  For Each LVReqingClassItem In ListViewReqingClass.ListItems
                    For Each LVReqingPayItem In ListViewReqingPay.ListItems
                      For Each LVHPCodesItem In ListViewHPCodes.ListItems
                        For Each LVHPOptionCodesItem In ListViewHPOptionCodes.ListItems
                          For Each LVPOSItem In ListViewPOS.ListItems
                            For Each LVReqdProvIDItem In ListViewReqdProvID.ListItems
                              For Each LVReqingProvIDItem In ListViewReqingProvID.ListItems
                                For Each LVAuthTypeItem In ListViewAuthType.ListItems
                                  For Each LVMembCondItem In ListViewMemberCondition.ListItems
                                      TempDe1.InsertRule _
                                         AdvancedRule, "Advanced", Me.TextGroup, Me.CheckAutoApprove.Value, _
                                         CDate(Me.DTPickerFromDt), CDate(Me.DTPickerToDt), ExpDate, _
                                         LVSvcItem.Text, LVSvcItem.ListSubItems(1).Text, LVDiagItem.Text, _
                                         LVDiagItem.ListSubItems(1).Text, IIf(LVSvcItem.ListSubItems.Count = 1, _
                                         "0", LVSvcItem.ListSubItems(LVSvcItem.ListSubItems.Count).Text), _
                                         LVReqdSpecItem.Text, LVReqdSpecItem.ListSubItems(1).Text, _
                                         LVReqdClassItem.Text, LVReqdClassItem.ListSubItems(1).Text, _
                                         LVReqdContItem.Text, LVReqdContItem.ListSubItems(1).Text, _
                                         LVReqdPayItem.Text, LVReqdPayItem.ListSubItems(1).Text, _
                                         LVReqingSpecItem.Text, LVReqingSpecItem.ListSubItems(1).Text, 
                                         LVReqingClassItem.Text, LVReqingClassItem.ListSubItems(1).Text, _
                                         LVReqingContItem.Text, LVReqingContItem.ListSubItems(1).Text, _
                                         LVReqingPayItem.Text, LVReqingPayItem.ListSubItems(1).Text, _
                                         LVHPCodesItem.Text, LVHPCodesItem.ListSubItems(1).Text, _
                                         LVPOSItem.Text, LVPOSItem.ListSubItems(1).Text, _
                                         LVReqdProvIDItem.Text, LVReqdProvIDItem.ListSubItems(1).Text, _
                                         LVReqingProvIDItem.Text, LVReqingProvIDItem.ListSubItems(1).Text, _
                                         TextDesc.Text, TextAgeFrom.Text, TextAgeTo.Text, _
                                         LVAuthTypeItem.Text, LVAuthTypeItem.ListSubItems(1).Text, _
                                         LVMembCondItem.Text, LVMembCondItem.ListSubItems(1).Text, _
                                         Me.cboRuleType.SelectedItem.Key, Me.txtRulePriority.Text, _
                                         Int(LVRefWarnItem.Text), Int(LVRefWarnItem.ListSubItems(1).Text), _
                                         LVHPOptionCodesItem.Text, LVHPOptionCodesItem.ListSubItems(1).Text
                                  Next
                                Next LVAuthTypeItem
                              Next LVReqingProvIDItem
                            Next LVReqdProvIDItem
                          Next LVPOSItem
                        Next LVHPOptionCodesItem
                      Next LVHPCodesItem
                    Next LVReqingPayItem
                  Next LVReqingClassItem
                Next LVReqingContItem
              Next LVReqdContItem
            Next LVSvcItem
          Next LVReqingSpecItem
        Next LVReqdSpecItem
      Next LVReqdPayItem
    Next LVReqdClassItem
  Next LVDiagItem
Next LVRefWarnItem
[Advertisement] BuildMaster allows you to create a self-service release management platform that allows different teams to manage their applications. Explore how!