>
Pessoal, estou na aula 4 e estou tendo problema do mapa vem em branco
segue abaixo meu codigo :
mapa.xml
android:layout_height="match_parent"
android:orientation="vertical" >
android:clickable="true"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:apiKey="AIzaSyCF_OvuvnC4XYlQy7g2rHkNElHK-QwKDgs"
/>
Manifest
android:versionCode="1"
android:versionName="1.0" >
android:targetSdkVersion="8" />
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
android:label="@string/app_name" >
>
>
>
public class MapShowActivity extends MapActivity{
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.mapa);
MapView map = (MapView)findViewById(R.id.mapaView);
map.setBuiltInZoomControls(true);
map.displayZoomControls(true);
Intent it = getIntent();
int latitude = (int)(it.getDoubleExtra("latitude",0)*1E6);
int longitude = (int)(it.getDoubleExtra("longitude",0)*1E6);
MapController mc = map.getController();
mc.animateTo(new GeoPoint(latitude,longitude));
mc.setZoom(30);
map.invalidate();
}
@Override
protected boolean isRouteDisplayed() {
// TODO Auto-generated method stub
return false;
}
}
public class ListaVendasActivity extends Activity{
@Override
protected void onCreate(Bundle savedInstanceState) {
@Override
public void onItemClick(AdapterView ad, View v, int position, long id) {
SQLiteCursor c = (SQLiteCursor)ad.getAdapter().getItem(position);
Intent it = new Intent(getBaseContext(), MapShowActivity.class);
it.putExtra("latitude", c.getDouble(c.getColumnIndex("la")));
it.putExtra("longitude", c.getDouble(c.getColumnIndex("lo")));
startActivity(it);
}
});
Olá
Ele esta passando as coordenadas?
Olá.. estou tendo o mesmo problema. O sistema está passando as coordenadas e já até validei no google maps.
Também tive este este problema. Alguém sabe a resposta?
Pessoal,
Vocês tiveram exito em gerar a API KEY?
O Google Maps lançou a nova versão do Maps, a RL System já está fazendo uma vídeo aula mostrando essa nova funcionalidade.