I try to program an easy map app on Android but the only outcome are errors. I tried to program it the way it should be but it still doesn\'t work.
mainactivity<
Check my answer below :
In your xml file change this class="com.google.android.gms.maps.MapFragment" to android:name="com.google.android.gms.maps.SupportMapFragment"
Extend your activity to FragmentActivty and change
map = ((MapFragment) getFragmentManager().findFragmentById(R.id.map)) .getMap(); to
map= ((SupportMapFragment) getSupportFragmentManager() .findFragmentById(R.id.map)).getMap();
Also check if (map== null) { map= ((SupportMapFragment) getSupportFragmentManager() .findFragmentById(R.id.map)).getMap();}
Check your manifest file :
Hope this helps.