android:layout_width="fill_parent"
android:layout_height="fill_parent">
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height ="match_parent"
android:layout_alignParentTop="true"
android:layout_alignParentLeft="true"
class="com.google.android.gms.maps.MapFragment"
map :uiRotateGestures="false"
map:uiScrollGestures="false"
map:uiZoomControls="false"
map:uiZoomGestures="false"
map:cameraZoom="18"
/>
android:id="@+id/scroller"
androi d:layout_width="250dp"
android:layout_height="100dp"
android:layout_alignParentTop="true"
android:layout_alignParentLeft="true"
android:background="@ android:color/white">
android:id="@+id/debug_text"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:textSize="10sp"
/>
If I even edit the file A character of “map”, all lines starting with “map” will be highlighted in red, and the fragment start tag will also be highlighted. The error I get is:
Unexpected namespace prefix "xmlns" found for tag fragment
For the line starting with “map”, the error is:
Unexpected namespace prefix "map" found for tag fragment
If I clean up the project, the problem will disappear, I can build and run the project very well, but since I am editing it a lot now, it is very annoying. Can anyone help?
I have an annoying problem. I am in my Android project Using Fragment, it makes me feel endless pain because I have to clean up the project every time I edit the main xml file. This is what it looks like:
xml version="1.0" encoding="utf-8"?>android:layout_width= "fill_parent"
android:layout_height="fill_parent">
android:id= "@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:layout_alignParentLeft="true "
class="com.google.android.gms.maps.MapFragment"
map:uiRotateGestures="false"
map:uiScrollGestures="false"
map:uiZoomControls= "false"
map:uiZoomGestures ="false"
map:cameraZoom="18"
/>
android:id="@+id/scroller"
android:layout_width= "250dp"
android:layout_height="100dp"
android:layout_alignParentTop="true"
android:layout_alignParentLeft="true"
android:background="@android:color/ white">
android:id="@+id/debug_text"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:textSize="10sp"
/>
If I even edit one character of the file, Then all lines starting with “map” will be highlighted in red, and the fragment start tag will also be highlighted. The error I get is:
Unexpected namespace prefix "xmlns" found for tag fragment
For the line starting with “map”, the error is:
Unexpected namespace prefix "map" found for tag fragment
If I clean up the project, the problem will disappear, I can build and run the project very well, but since I am editing it a lot now, it is very annoying. Can anyone help?
In Eclipse, you can go to Project -> Automatic Build, which should include a clean process. You can also use adb to build ANT scripts, and use The build.xml file sets the cleanup target as part of the build.