code:
Public WithEvents MsgrUIA As MessengerAPI.Messenger
Public MsgrContact As MessengerAPI.IMessengerContact
Private Sub btnBlocked_Click()
On Error Resume Next
Dim strSigninName As String
Dim strServiceID As String
'Get selected contact
strSigninName = ListContact.SelectedItem.SubItems(2)
strServiceID = ListContact.SelectedItem.SubItems(5)
Set MsgrContact = Nothing
Set MsgrContact = MsgrUIA.GetContact(strSigninName, strServiceID)
ErrorTrap ("GetContact") 'Error handling routine
If MsgrContact.Blocked = True Then
MsgrContact.Blocked = False
MsgBox ("Contact: " & CStr(MsgrContact.SigninName) & " is now Unblocked")
Else
MsgrContact.Blocked = True
MsgBox ("Contact: " & CStr(MsgrContact.SigninName) & " is now Blocked")
End If
ErrorTrap ("Contact.Blocked") 'Error handling routine
populateListView 'Refresh contact list
End Sub
The following are what my code complains about