Thanks that works, but I have a small issue again.
I need to filter a recordset twice. It need to filter based on a UserID in a form field on the page, and the UserID of the logged in user to see if the database table contains a record with both the users. Hence, they are friends already.
My plan was then to use "show if" to display messages. However I cannot make it work. Is my SQL incorrect?
WHERE UserID = colname AND FriendID = colnamem