How do I show a Popup?

05-10-2018 09:44 AM
New Contributor II

In the latest 100.2.1 for Xamarin.Forms, how do I show a popup?  I see that the map view has a show callout, but no show popup.  I see that I can define my popup per layer with popupdefinition, but I see no way to actually show the UI for the popup.  I have search many different posts, and this answer is not clear.  Some show examples of a customized callout with a table of labels and properties, but it may have been WPF only??  I am looking for a Xamarin.Forms solution.  I saw an ESRI response saying that displaying the popup UI is app specific and you are on your own, but that was over 1 year ago.  I would respond with, it should not be 100% app specific.  Sure the content of the popup UI is app specific, but the showing of it and anchoring it to the map so when I pan, the popup pans with it, and the leader graphic that points to the feature that was clicked should all be handled by ESRI.

If this is not yet supported in the Xamarin.Forms version, then please be clear and say so and also reveal if there are plans to add this and when.  Thanks.

3 Replies
Occasional Contributor

You might say i have the same question. I see sample code for a callout, but i am looking for sample code for a simple form that can be used to add/edit a feature. It sounds pretty simple but can't locate it...

0 Kudos
Esri Notable Contributor

We're planning on providing something like this in the toolkit, but it is still work-in-progress. You might want to look at the PopupManager class, which serves as a ViewModel for such a UI View.

Occasional Contributor

Okay. I looked into the PopupManager Class. I can adjust a lot of the properties and create a popup object and assign it to a geo-element, but then i struggle to display the popup. In other words, i struggle with creating the User Interface part of the popup.

I looked for sample code but its been tough. I was originally looking for method, something similar to popup.Show() or popUp.Display() but i am guessing now that its not that easy.......

What would you recommend? Can i push my popup to callout? Anyway, i am interested to see what you would recommend.

0 Kudos