I am facing some issue\"Null pointer Expcepttion at getmap()\" in Google Map Fragments . I want to insert mapfragment in a fragment Please review the code and let know whet
Remove all the fmap code:
SupportMapFragment fmap = (SupportMapFragment) getFragmentManager().findFragmentById(R.id.map); if (fmap == null) { fmap = SupportMapFragment.newInstance(); ft.add(R.id.map, fmap); }
You already have an instance of the map saved as the "map" variable, so use that one.