i write simple google map v2 android application but in my java file this line:
googleMap = ((SupportMapFragment) getFragmentManager().findFragmentById(R.id.map)).getMap();
have error! error:the getFragmentManager() is undefined for the type mainActivity. please help me my friends.
If you used SupportMapFragment
then used getSupportFragmentManager()
and if you used MapFragment
then used getFragmentManager()
googleMap = ((SupportMapFragment) getSupportFragmentManager().findFragmentById(R.id.map)).getMap();