I tried so hard to solve a problem.
I am using the Google Map V2 API and I followed all the steps from the google tutorial but there is a problem I don't understand :
I took care to define the same version for both of them (Google API 5.0.1)
The check is now green but in my main Activity from my main project, Eclipse can't import any class from "com.google.android.gms.maps"
Is there someone who have a solution please ?
import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import com.example.moodwalk.R;
import com.google.android.gms.maps.model.LatLng;
public class GoogleResult extends FragmentActivity {
static final LatLng HAMBURG = new LatLng(53.558, 9.927);
static final LatLng KIEL = new LatLng(53.551, 9.993);
private GoogleMap map;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.login_accueil);
}
}
确保您已在属性选项卡下将Google Play服务和google util库添加为项目的libs。
When you Select Android on the left selection which adding he library. See the above table and check the Android xx not Google API. Once you do you should add the Google Play Services Library and then run the project. It wont throw that error anymore.
Ok, I found my error. For them who have the same problem, check if you don't have a different path for your androi-support-v4 in your project and library project.
I deleted the both jar and then added one in each libs project with the same path. It worked for me !
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.