Need GoogleMap api to get it.

Topics: Etc...
Sep 23, 2011 at 6:50 AM
Edited Sep 23, 2011 at 7:04 AM
if i use GMapProviders.GoogleMap,the map can't show.if i use other GMapProviders like LithuaniaMap,it can show well.
GoogleMap needs GoogleMap api key.where and how can i get it?.
i find this, but it needs url for this url my IP adress?
could u help me or tell me how to use GMapProviders.GoogleMap in C# project?
using System;
using System.Linq;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Data.SQLite;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using GMap.NET;
using GMap.NET.WindowsForms;
using GMap.NET.WindowsForms.Markers;
using GMap.NET.MapProviders;
using Microsoft.WindowsCE.Forms;

namespace MapNet
    public partial class Form1 : Form
        private GMapControl _map;
        public Form1()
        private void initMapControl()  
            _map = new GMapControl();  
            _map.BackColor = System.Drawing.Color.White;  
            _map.CanDragMap = true;  
            _map.Dock = System.Windows.Forms.DockStyle.Fill;  
            _map.Location = new System.Drawing.Point(0, 0);  
            _map.MapProvider = GMapProviders.GoogleMap;
            //GMapProviders.GoogleMap.APIKey = "";
            _map.MarkersEnabled = true;   
            _map.Name = "MainMap";  
            _map.RoutesEnabled = true; 
            _map.ShowTileGridLines = false; 
            _map.TabIndex = 0;
            _map.Manager.Language = LanguageType.ChineseSimplified; 
            _map.Zoom = trackBar1.Value;  

        private void Form1_Load(object sender, EventArgs e)
            PointLatLng current = new PointLatLng(119.276173, 26.111844);
            GMapMarkerGoogleGreen currentMark = new GMapMarkerGoogleGreen(current);
            GMapOverlay overlay = new GMapOverlay(_map, "current");  
Sep 23, 2011 at 7:12 AM
Edited Sep 23, 2011 at 7:26 AM

it has nothing to do with api key, you don't need it to display the map

Sep 23, 2011 at 7:56 AM


This is the same question i asked before.


Maybe it's my net problem.