Class: Contact |
How to Read: Property/Method(Parameter As Type, ...) As ReturnValue |
General Properties |
ErrorMsg() As String Purpose: Return Error Message if a method failed or no records were found |
ContactID() As Long Purpose: Return Contact ID |
ContactID(ID As Long) Purpose: Set Contact ID to update a specific record |
Username() As String Purpose: Return EmailAddress as Username |
Username(EmailAddress As String) Purpose: Set EmailAddress as Username for record update |
Password() As String Purpose: Return User Password |
Password(UserPassword As String) Purpose: Set User Password for record update |
DisplayName() As String Purpose: Return Display Name |
DisplayName(NameForDisplay As String) Purpose: Set Display Name for record update |
ContactIndex() As Integer Purpose: Return current Contact Index |
ContactCount() As Integer Purpose: Return Contact Count after calling GetContacts() |
ContactEnd() As Boolean Purpose: Used with GetContacts() and NextContact() |
General Methods |
GetContacts() As Boolean Purpose: Return all Contact DB records Use ContactByindex() to retrieve records by Index [ 1 to ContactCount() ] Requires: (String) Contact ID Number Returns: True - successful; False - error or no records were found |
NextContact() As Boolean Purpose: Return data for next contact found |
ContactByIndex(Index As Integer) As Boolean Purpose: Return Contact data for a given Index after calling GetContacts() Requires: Index - number between 1 and ContactCount() Returns: True - successful; False - error |
GetContactByID(ContactID As Long) As Boolean Purpose: Search DB for record that contains Contact ID Number in 'cont_id' field Requires: (Long) Contact ID Number Returns: True - successful; False - error or no records were found |
GetContactByUsername(EmailAddress As String) As Boolean Purpose: Search DB for record that contains EmailAddress in 'username' field Requires: (String) valid Email Address Returns: True - successful; False - error or no records were found |
ValidateUser(EmailAddress As String, Password As String) As Boolean Purpose: Search DB for record that contains EmailAddress in 'username' field Requires: (String) valid Email Address Returns: True - successful; False - error or no records were found |
UpdateContactDB() As Boolean Purpose: Update DB record for given ID - Set values using the Contact properties (ContactID, Username, ...) Use ContactID(0) to Add a record to the DB Use ContactID(ID) to Update a record by ID Returns: True - successful; False - error |
DeleteContact(PictureFilePath As String, ContactID As String) As Boolean Purpose: Delete Contact record from database and remove all Image references Requires: Conact ID Returns: True - successful; False - error |
ResetContactVars() Purpose: Reset all Contact variables |