I'm trying to add a google mapview to an existing fragment. Following the instructions from the developer docs, I've included the following xml in my fragment:
<fragment
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"
class="com.google.android.gms.maps.MapFragment" />
However, I end up getting an IllegalArgumentException every time:
02-28 18:54:21.133: E/AndroidRuntime(11300): Caused by: java.lang.IllegalArgumentException: Binary XML file line #158: Duplicate id 0x7f050019, tag null, or parent id 0x0 with another fragment for com.google.android.gms.maps.SupportMapFragment
02-28 18:54:21.133: E/AndroidRuntime(11300): at android.support.v4.app.FragmentActivity.onCreateView(FragmentActivity.java:285) 02-28 18:54:21.133: E/AndroidRuntime(11300): at android.view.LayoutInflater.createViewFromTag(Layout
Any workarounds for this?