android - Calling acitivity from "OnMapClickListener()" not working -


i have tried lot of examples none of them worked.

mmap.setonmapclicklistener(new googlemap.onmapclicklistener() {         @override         public void onmapclick(latlng latlng) {             markeroptions markeroptions = new markeroptions();             markeroptions.position(latlng);             markeroptions.title(latlng.latitude + " : " + latlng.longitude);             mmap.clear();             mmap.animatecamera(cameraupdatefactory.newlatlng(latlng));             mmap.addmarker(markeroptions);             intent in = new intent(getapplicationcontext(),mainmenu.class);             startactivity(in);         }     }); 

marker added map unfortunately shows error. when click ok goes next activity.


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -