What is happening:: I am not able to find the map view that returns this line fm.findFragmentById(R.id.mySupportMapId) as null
CODE
in onResume:
FragmentManager fm=getActivity().getSupportFragmentManager();
SupportMapFragment smf = (SupportMapFragment) fm.findFragmentById(R.id.mySupportMapId);
googleMap=smf.getMap();
in xml
<FrameLayout
android:id="@+id/rootJobsLocationId"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical" >
<fragment
android:id="@+id/mySupportMapId"
android:name="com.google.android.gms.maps.SupportMapFragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="center" />
other code
Error
smf becomes null
note: i have a device that has google play services.... this error was not there when i was using regularfragment instead of support fragment
if (mMap == null)googleMap==nulli checked , its true so it goes inside the condition