C clooney48 Active Member Licensed User Longtime User Oct 14, 2014 #1 Hi all! With the following code I show all my POIs on Gmaps. When I click on a POI the name of the POI is shown. That works fine. Now I would like to add a Doubleclick or Longclick to perform an action for each POI. I tried it with a "MarkerLongClick" statement (because "MarkerClick" exists) but apparently this doesn´t exist. I don´t find the correct code (but the click event should work nevertheless). Thanks for help! Sub ShowMap .... gmap.AddMarker(Lat1, Lon1, Name) .... End Sub Sub map_MarkerLongClick (SelectedMarker As Marker) As Boolean Msgbox("YES","") Return True End Sub Click to expand...
Hi all! With the following code I show all my POIs on Gmaps. When I click on a POI the name of the POI is shown. That works fine. Now I would like to add a Doubleclick or Longclick to perform an action for each POI. I tried it with a "MarkerLongClick" statement (because "MarkerClick" exists) but apparently this doesn´t exist. I don´t find the correct code (but the click event should work nevertheless). Thanks for help! Sub ShowMap .... gmap.AddMarker(Lat1, Lon1, Name) .... End Sub Sub map_MarkerLongClick (SelectedMarker As Marker) As Boolean Msgbox("YES","") Return True End Sub Click to expand...
Erel B4X founder Staff member Licensed User Longtime User Oct 15, 2014 #2 You can see the available events here: http://www.b4x.com/android/help/googlemaps.html#mapfragment You can also see them in the IDE (see the IDE Tips link in my signature). Upvote 0
You can see the available events here: http://www.b4x.com/android/help/googlemaps.html#mapfragment You can also see them in the IDE (see the IDE Tips link in my signature).
C clooney48 Active Member Licensed User Longtime User Oct 15, 2014 #3 Dear Erel! Thanks, but this doesn´t really help me (at least I can´t find it). I wanted only to know the correct call for a longclick because Sub map_MarkerLongClick (SelectedMarker As Marker) As Boolean Click to expand... doesn´t obviously work. Upvote 0
Dear Erel! Thanks, but this doesn´t really help me (at least I can´t find it). I wanted only to know the correct call for a longclick because Sub map_MarkerLongClick (SelectedMarker As Marker) As Boolean Click to expand... doesn´t obviously work.
Erel B4X founder Staff member Licensed User Longtime User Oct 16, 2014 #4 There is no such event. Upvote 0
warwound Expert Licensed User Longtime User Oct 16, 2014 #5 clooney48 said: Now I would like to add a Doubleclick or Longclick to perform an action for each POI. Click to expand... You can listen for a click on the InfoWindow: http://www.b4x.com/android/forum/threads/google-maps-android-v2-tutorial.24415/page-6#post-166741. Is that any use to you? Martin. Upvote 0
clooney48 said: Now I would like to add a Doubleclick or Longclick to perform an action for each POI. Click to expand... You can listen for a click on the InfoWindow: http://www.b4x.com/android/forum/threads/google-maps-android-v2-tutorial.24415/page-6#post-166741. Is that any use to you? Martin.
C clooney48 Active Member Licensed User Longtime User Oct 16, 2014 #6 Hi warwound! I tried it but I get always the error: AndroidManifest.xml:26: error: No resource identifier found for attribute 'largeHeap' in package 'android' Click to expand... although I have copied the jar and xml file of GoogleMapsExtras to the library directory. Upvote 0
Hi warwound! I tried it but I get always the error: AndroidManifest.xml:26: error: No resource identifier found for attribute 'largeHeap' in package 'android' Click to expand... although I have copied the jar and xml file of GoogleMapsExtras to the library directory.
Beja Expert Licensed User Longtime User Oct 16, 2014 #7 Besides you can use the click event then branch to two options and work on the one the user selects. (consider it double-click because there you are also clicking twice, aren't you _) Upvote 0
Besides you can use the click event then branch to two options and work on the one the user selects. (consider it double-click because there you are also clicking twice, aren't you _)
warwound Expert Licensed User Longtime User Oct 17, 2014 #8 clooney48 said: Hi warwound! I tried it but I get always the error: although I have copied the jar and xml file of GoogleMapsExtras to the library directory. Click to expand... Sounds like you're compiling with a version of android prior to honeycomb. In the IDE find the 'configure paths' option and then select a newer version of android.jar. This is unrelated to using GoogleMapsExtras btw. Upvote 0
clooney48 said: Hi warwound! I tried it but I get always the error: although I have copied the jar and xml file of GoogleMapsExtras to the library directory. Click to expand... Sounds like you're compiling with a version of android prior to honeycomb. In the IDE find the 'configure paths' option and then select a newer version of android.jar. This is unrelated to using GoogleMapsExtras btw.
C clooney48 Active Member Licensed User Longtime User Oct 19, 2014 #9 So I updated the Android version. Now I get this error: Parsing code. Error Error parsing program. Error description: Unknown type: webviewextras Are you missing a library reference? Occurred on line: 157 Dim MapViewerExtra As WebViewExtras Click to expand... Which library is this?? Didn´t find it. OSMDroid? Upvote 0
So I updated the Android version. Now I get this error: Parsing code. Error Error parsing program. Error description: Unknown type: webviewextras Are you missing a library reference? Occurred on line: 157 Dim MapViewerExtra As WebViewExtras Click to expand... Which library is this?? Didn´t find it. OSMDroid?
C clooney48 Active Member Licensed User Longtime User Oct 19, 2014 #10 Hi Beja! This is an idea ! Thanks! Upvote 0
warwound Expert Licensed User Longtime User Oct 19, 2014 #11 Dim MapViewerExtra As WebViewExtras Click to expand... Where did that come from? looks like an error to me. Upvote 0
Dim MapViewerExtra As WebViewExtras Click to expand... Where did that come from? looks like an error to me.
C clooney48 Active Member Licensed User Longtime User Oct 20, 2014 #12 It appeared when I run an example but I can´t find it anymore. Upvote 0