Send Button Not Triggering Event

Hello,

I am using version 18.2.0.45 to try and add a chat feature to my app. Everything is working as expected except on iOS the send button (with icon, not keyboard button) does not trigger the send message event. The send button on the keyboard works correctly. On Android, both the keyboard and the send button work. I am able to click it, just nothing triggers. I have tried both the Event Handler and Command approach. Here is what my code looks like:

XAML:

<ContentPage.Content>
        <sfChat:SfChat AbsoluteLayout.LayoutBounds="0, 0, 1, 1" AbsoluteLayout.LayoutFlags="All"
                x:Name="chat"
                Messages="{Binding Messages}"
                CurrentUser="{Binding CurrentUser}"
                ShowOutgoingMessageAvatar="False"
                TypingIndicator="{Binding TypingIndicator}"
                ShowTypingIndicator="{Binding ShowTypingIndicator}"
                CanAutoScrollToBottom="True"
                ShowIncomingMessageAvatar="True"
                AllowMultilineInput="False"
                MessageShape="RoundedRectangle"
                BackgroundColor="{DynamicResource PageBackgroundColor}"/>
    </ContentPage.Content>

CODEBEHIND:

public ChatPage(Team team)
        {
            InitializeComponent();

            On<iOS>().SetUseSafeArea(true);

            chatService = new ChatService();
            this.BindingContext = viewModel = new ChatViewModel();

            this.chat.SendMessage += this.Chat_SendMessage;
            this.chat.Editor.TextChanged += Editor_TextChanged;
            this.chat.Editor.Unfocused += Editor_Unfocused;
        }

private async void Chat_SendMessage(object sender, SendMessageEventArgs e)
        {
            TextMessage chatMessage = (TextMessage)e.Message;
            if (chatMessage.Author == viewModel.CurrentUser)
            {
                await chatService.SendMessage(viewModel.CurrentUser.Name, chatMessage.Text, true, viewModel.CurrentUser.Avatar.ToString(), team.ChatGroupId);
            }
            e.Handled = true;
        }

Is there something I am missing, or a workaround for me to manually bind the command to the button on iOS?

Thank you.

4 Replies 1 reply marked as answer

KK Karthikraja Kalaimani Syncfusion Team July 16, 2020 12:55 PM UTC

Hi Todd,

Currently, we are checking the issue “Send button did not triggering in iOS platform”. We will update  further details on or before 20th July 2020. We appreciate your patience until then.

Regards,
Karthik Raja
 



SS Sivaraman Sivagurunathan Syncfusion Team July 20, 2020 01:02 PM UTC

Hi Todd, 

Thanks for using Syncfusion support.  

We have checked the reported issue from our side we are able to reproduce the reported issue in iOS 13.4 version. This issue due to Xamarin.iOS SDK. There is break in gesture and they are fixed the issue and it will be available in next Xamarin.iOS SDK itself. Also they have workaround for the same. Kindly refer the following GitHub link for more details.   


Regards,  
Sivaraman S 


Marked as answer

TA Todd Arneson July 20, 2020 06:05 PM UTC

Hello, 

The link you provided was exactly the issue. Was able to resolve, and send button is working correctly now. 

Thank you.


KK Karthikraja Kalaimani Syncfusion Team July 21, 2020 06:05 AM UTC

 
Hi Todd,

Thanks for the update.

We are glad to know that the reported problem has been resolved at your end. Please let us know if you have any further queries on this. We are happy to help you.  

Regards,
Karthik Raja
 


Loader.
Up arrow icon