I am trying to do a location app and am in the trouble shooting phase right now. I am down to my last two problems and they both relate to R. blah blah. It says main is either not a field or cannot be resolved and the same message but with mapview instead of main. Below are my imports and the lines of code where the issue is.
Code:
setContentView(R.layout.main);
mapview = (MapView)findViewById(R.id.mapview);
Imports:
import android.R;
import android.R.layout;
import android.R.id;
import android.location.Location;
import android.location.LocationListener;
import android.location.LocationManager;
import android.os.Bundle;
import android.widget.Toast;
import com.google.android.maps.GeoPoint;
import com.google.android.maps.MapActivity;
import com.google.android.maps.MapController;
import com.google.android.maps.MapView;
I've tried everything. I know people keep saying to take out android.R but that is where R.layout and R.id are found in the jar files. I have right clicked the folder and validated the code. I have gone to Project/Clean and done that. No luck. Please help? And this is my first post so I'm sorry if its formatted wrong. I thank you in advance for any help you give me. Here is my main.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Waiting for location..."
android:id="@+id/lblLocationInfo"
/>
<com.google.android.maps.MapView
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/mapview"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:clickable="true"
android:apiKey="0vFrUOhHMkbahT9zXqiz_DuNVWfPqlEyqcO8ftg"
/>
</LinearLayout>