Questions tagged [messagingcenter]

41 questions
5
votes
3 answers

What is the difference between using MessagingCenter and standard .NET event handlers for informing interested parties of changes?

What is the difference between using MessagingCenter and standard .NET event handlers for informing interested parties of changes? Two (untested) implementations of the same thing are below to demonstrate: public class FooClass { public event…
Pranay Deep
  • 1,371
  • 4
  • 24
  • 44
4
votes
1 answer

How to stop messaging center to stop subscribe multiple time in Xamarin.Forms?

I am creating an application and in that it need to send argument to the other page and send argument using the Messagingcenter when I send using MessagingCenter it call more than one time. If I am using unscribe than in next time it is not receive…
Deep Soni
  • 431
  • 4
  • 24
3
votes
1 answer

C# Xamarin Forms MessagingCenter not updating Item passed

I am using MessagingCenter to passe objects throu my pages, from my LoginPage to my MainPage. Even tho the object is updated, when using it to my mainpage, the object seems to be null. public User sUser { get; set; } public MainPage() { …
Alejandro
  • 308
  • 2
  • 11
3
votes
5 answers

Xamarin Forms MessagingCenter Subscribe called two times

I'm clicking on a product item in listview in product page viewmodel to show a popup(using rg.plugin popup) for selecting one of the product variants.After selecting variant,i am sending the selected variant to product page using messagingcenter…
Vipin Krishna
  • 355
  • 1
  • 4
  • 25
3
votes
0 answers

How do I send a message using MessagingCenter from PCL to iOS with Xamarin Forms?

I am creating a cross-platform mobile app with Xamarin, and I am trying to use MessagingCenter to send a message when an event occurs. The event should be handled differently depending on if the phone is running iOS or Android. I am able to send a…
adhdj
  • 352
  • 4
  • 17
2
votes
1 answer

Xamarin MessagingCenter: sending once, receiving multiples

I'm experiencing an annoying issue with xamarin messaging center. I added some break points and noticed that only one message is sent but the subscriber receives it twice. My sender code(Page2): async void CompartilhaMapa(System.Object sender,…
Éder Rocha
  • 1,538
  • 11
  • 29
1
vote
1 answer

How do I send a list of objects through MessagingCenter in C#?

I am trying to send list of BarData objects to my FavoritesPage.xaml.cs through MessagingCenter. I have tried MessagingCenter.Send(_favoriteBarsList, "FaveBars"); and it gives me an error, telling me I can't convert the sender from a list…
1
vote
1 answer

MessagingCenter not subscribing

I'm new to Xamarin (and new in coding in general). I'm using xct TouchEffect within a ListView to try to get a LongPress menu. Since the TouchEffect.LongPressCommand is a Command, I can only bound it to the model page from some reason. So... I'm…
Noah
  • 15
  • 1
  • 6
1
vote
0 answers

how to resolve messagingcenter.subscribe calling multiple times in xamarin.forms

MessagingCenter.Subscribe calling multile times but i called MessagingCenter.send only one time.how to resolve this issue. I'm subscribe from model's constructor MessagingCenter.Subscribe>(this, "hi", async (arg1, list) => …
Dev
  • 315
  • 2
  • 16
1
vote
1 answer

Xamarin Forms MessagingCenter does not receive message

I have downloaded MultiImagePicker from this link : https://github.com/danielkon96/MultiImagePickerand it's working fine without any problem . When I add all interfaces and classes and... in my project , the MessagingCenter does not receive message…
mm sh
  • 192
  • 3
  • 18
1
vote
2 answers

Xamarin Multiple Entries With Messaging Center

Hi Im trying to send multiple entries with messeging center but couldnt manage it (im new on xamarin and couldnt found proper examples for my code) im trying to idenify messages on confirm page (_entry1 you will go here _entry2 you will go…
Henimex
  • 43
  • 6
1
vote
1 answer

Having trouble using MessagingCenter to send a message from Android MainActivity to view model class not in Android project

I attempted to follow the instructions found here to add a MessagingCenter subscribe action on a notification tap that would open a specific view. Somewhere my Send / Subscribe aren't talking to each other and I just can't see where. The details of…
1
vote
2 answers

MessagingCenter is working on WPF but not working on Android

I created this app to answer some questions regarding MessagingCenter, but I am not able to continue the code due to a problem running the application specifically on the Android platform, if you know what may be wrong please help me. Thanks for the…
MATCH
  • 100
  • 10
1
vote
1 answer

How do I send data back to the parent page in xamarin forms?

There is a label in the page Account which when tapped on will create a new ContentPage with a list of premise addresses. Tapping on any of the addresses should pop the ContentPage and send back a value to the Account page to set certain fields…
Scar
  • 725
  • 2
  • 7
  • 28
1
vote
2 answers

Send string from Android project to PCL with MessagingCenter

This is my first post on this forum so any tips on how to make the question more understandable/readable and so on is appreciated. What am I doing? I am making my first app using Xamarin Forms, and I have two projects, PCL (Portable Class Library)…
Razze
  • 11
  • 1
  • 7
1
2 3