.Net Runtime 100.2 CallOutDefinition - Unable to trigger map tapped event

366
5
04-17-2018 11:03 AM
JimFiddes
Occasional Contributor

I've been successful at getting my callout to appear with a button image and even have the image clickable to trigger further work. However, when I touch the screen with my finger it does not trigger the button click event and am wondering how I can go about using a touch event to fire the action related to the button?

Code example:

if (MyGraphic.HasLayout)
{
//a button is needed in the callout definition
var converter = new ImageConverter();
var png = Properties.Resources.Form;
def.ButtonImage = new RuntimeImage((byte[])converter.ConvertTo(png, typeof(byte[])));
Action<object> infoWindowButtonClick_Process = MoreDetailsClicked;
def.OnButtonClick = infoWindowButtonClick_Process;
}

My click event being handled:

private void MoreDetailsClicked(object message)
{
 //do further work
}

0 Kudos
5 Replies
dotMorten_esri
Esri Frequent Contributor

Which platform are you targeting?

0 Kudos
JimFiddes
Occasional Contributor

Not sure what you are looking for so here are some general answers:

1. Any CPU

2. Windows

0 Kudos
dotMorten_esri
Esri Frequent Contributor

The .NET Runtime supports 4 platforms: WPF, Windows Universal (UWP), Android and iOS, as well as a Xamarin.Forms layer on top of the 3 latter ones. I guess we can rule out Android and iOS, so is it WPF or UWP?

0 Kudos
JimFiddes
Occasional Contributor

Sorry wasn't clear on what you were asking there. WPF for this particular question.

0 Kudos
SkyWatch
New Contributor

Jim Fiddes‌, did you ever find a reason or a solution to this issue? We are experiencing a similar thing with callouts and touch events in a WPF application (although version 100.4).

0 Kudos