RoofCo.cls Public CompanyName As String Public Address As String Public City As String Public State As String Public Zip As String Public Sqs As Double Public BidAmount As Currency Public BidMaterial As String Public Bid2Amount As Currency Public Bid2Material As String Public Sdate As String Public BusYrs As Integer Public Estimator As String Public Email As String Public Notes As String Public Phones As String '(mshflexgrid gridPhones) Public Tasks As String '(mshflexgrid grid2Column)
How can this be done ?
RoofCoCollection.cls Private m_RoofCompany As Collection ' Add an RoofCo object to the collection. Public Sub Add(ByVal emp As RoofCo, Optional ByVal key As Variant) If IsMissing(key) Then m_RoofCompany.Add emp Else m_RoofCompany.Add emp, key End If End Sub ' Return the number of items in the collection. Public Function Count() As Long Count = m_RoofCompany.Count End Function ' Return an RoofCo object. Public Function Item(ByVal Index As Variant) As RoofCo ' Set Item = m_RoofCompany(Index) End Function Public Sub Remove(ByVal Index As Variant) m_RoofCompany.Remove Index End Sub Public Function NewEnum() As IUnknown Set NewEnum = m_RoofCompany.[_NewEnum] End Function Private Sub Class_Initialize() Set m_RoofCompany = New Collection End Sub
From novice to tech pro — start learning today.