Hi All,
I’ve set up a DM function on my app using comments.
Each user can create a DM with another and exchange messages via comments. This has been the easiest way for me to set up a DM.
Here’s how it works:
- User A clicks on a DM button on User B’s profile
- An inline list appears creating a DM between User A and User B
- In a Google sheet called “Chats” a row is added with the emails of User A (sender) and User B (receiver), as well as a unique Chat ID.
- Once in the chat, User A and User B can comment (message) each other
- A new row is added in the default Glide “Comments” Google sheet
Now for the problem:
I set up a vlookup, pulling the Chat ID and from Comments and using that to find the recipient of the DM (comment).
However, the vlookup only works when details are pre-populated. I.e. it doesn’t populate properly when new rows are added.
Does anyone have any tips?
I’d like to set it up such that each time a new DM (comment) is added, the person the DM is intended for gets a notification that they have a DM.
I have no problem setting up the email, but it’s the logic to get the email to the right person that’s tricky!