Version 1.0 Class
Attribute VB_Name = "AddressObject"
Attribute VB_Creatable = True
Attribute VB_Exposed = True
Attribute VB_Description = "Address Book OLE Object"
Const NAME_FLD = 1
Const STREET_FLD = 2
Const STREET2_FLD = 3
Const CITY_FLD = 4
Const STATE_FLD = 5
Const ZIP_FLD = 6
Const PHONE_FLD = 7
Const WORK_FLD = 8
Const FAX_FLD = 9
Const NOTES_FLD = 10
Const FIRST_FLD = NAME_FLD
Const LAST_FLD = NOTES_FLD

Private Sub Class_Initialize()
   Address.Visible = False
   Load Address
   Address.Command1_Click
End Sub

Private Sub Class_Terminate()
    If Address.Visible = False Then
        Unload Address
    End If
End Sub


Public Sub FindTelephoneNumbers()
    Address.FindFirst_Click
End Sub

Public Static Property Get Name() As String
    FirstName = Address.AddressCtl(NAME_FLD)
End Property

Public Static Property Let Name(Value As String)
    Address.Command1_Click
    Adress.AddressCtl(NAME_FLD) = Value
End Property

Public Static Property Get Phone() As String
    Phone = Address.AddressCtl(PHONE_FLD)
End Property

Public Static Property Let Phone(Value As String)
    Address.Command1_Click
    Adress.AddressCtl(PHONE_FLD) = Value
End Property

Public Static Property Get Workphone() As String
    Workphone = Address.AddressCtl(WORK_FLD)
End Property

Public Static Property Let Workphone(Value As String)
    Address.Command1_Click
    Adress.AddressCtl(WORK_FLD) = Value
End Property

Public Static Property Get Fax() As String
    Fax = Address.AddressCtl(FAX_FLD)
End Property

Public Static Property Let Fax(Value As String)
    Address.Command1_Click
    Adress.AddressCtl(FAX_FLD) = Value
End Property
