How to have multiple users in a chat

I have created a messaging app and I have got it so the current user can send a message to an individual user. I used a guide online but the video only covered half of what i needed to create, and doesn’t cover off creating a chat with multiple users. Can anyone help in creating a chat that has multiple users?
Below is my data structure:

Users

Message

Chat

To create an individual chat i have done the below:
I create a new contact (which is a user on the system) I then click the user’s name listed in a repeating group:

I then have the following 2 workflows to create the chat:

To create the group chat i have set up the below pop up which has a multi dropdown search for all users on the system for them to select the users they want in the chat. I then want them to press the save button to create the group chat but i can’t work out how to get it to populate a chat with more than one user
image

Any help on how to set up the workflow would be really appreciated.

What does the workflow look like to set up a group chat? Assuming you are using add list or set list in your expression and the button is what triggers the creation of the Chat, it should be working.

Hi @Keymaker
Thank you for your reply. This is what i cant work out. How to create the group. to then add that group to a chat.
Is my logic of having a multiline dropdown the right solution? if not what would work?
If it is the right way what the workflow i need to do to create the group and add them all to a chat?
Thanks Sean

I would just create a normal Chat and then add both Users to Chat-Users since it’s a List of Users attribute. So the workflow would be:

  1. Trigger: Button Save clicked only when Multidropdown A is not empty
  2. Create a new Chat
    • Group-Chat-Title: Input Group Name
    • Chat-Users: set list from Multidropdown A’s value
    • Is-Group-Chat: yes
  3. Display data in a Group Chat display

This isn’t accounting for some of the other workflow steps in your working workflow so I don’t have the full context (namely, what changes are being made to the Users in a Chat), but otherwise it should work.

This is where i am having the problem i am not able to use the multi dropdowns values as it isnt an option.

What am i doing wrong? thr dropdown is set up as below:

is there a better way to create the group chat at all rather than the multi dropdown or am i just missing something?

The tutorial you watched probably told you to set the data type of the Multidropdown to text - which in my opinion isn’t the most workflow-friendly. If you set the “Type of choices” to User and remove each item's Name from “Choices source,” it should work as long as the Multidropdown is not inside of a repeating group.

TL;DR: it isn’t working right now because you’ve configured the Multidropdown to be a list of texts, and the workflow is asking for a list of Users.

1 Like

Thanks Key Maker i have got this working really appreciate it

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.