home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Visual Database / Visual BASIC 5.0 (Ent. Edition) / Vb5ent Extractor.EXE / VB / SAMPLES / PGUIDE / PROGWOB / PWOSBUS1.CLS < prev    next >
Encoding:
Visual Basic class definition  |  1996-11-26  |  1.1 KB  |  49 lines

  1. VERSION 1.0 CLASS
  2. BEGIN
  3.   MultiUse = -1  'True
  4. END
  5. Attribute VB_Name = "SmallBusiness1"
  6. Attribute VB_GlobalNameSpace = False
  7. Attribute VB_Creatable = False
  8. Attribute VB_PredeclaredId = False
  9. Attribute VB_Exposed = False
  10. Option Explicit
  11. ' >> Best viewed in Full Module view. <<
  12. '
  13. ' Storage for debug ID number.
  14. Private mlngDebugID As Long
  15. Implements IDebug
  16.  
  17. ' Public Collection object is easy to
  18. '   declare, but it leads to trouble --
  19. '   as shown in frmStraw.
  20. Public Employees As New Collection
  21.  
  22. Property Get NewEmployeeID() As String
  23.     Static intEmpNum As Integer
  24.     intEmpNum = intEmpNum + 1
  25.     NewEmployeeID = "E" & Format$(intEmpNum, "00000")
  26. End Property
  27.  
  28. Private Sub Class_Initialize()
  29.     mlngDebugID = DebugInit(Me)
  30. End Sub
  31.  
  32. Private Sub Class_Terminate()
  33.     DebugTerm Me
  34. End Sub
  35.  
  36. ' -------- IDebug Implementation --------
  37. '
  38. ' IDebug.DebugID gives you a way to tell
  39. ' ====== -------    objects apart.  It's
  40. '   required by the DebugInit, DebugTerm,
  41. '   and DebugShow debugging procedures
  42. '   declared in modFriend.
  43. '
  44. Private Property Get IDebug_DebugID() As Long
  45.     IDebug_DebugID = mlngDebugID
  46. End Property
  47.  
  48.  
  49.