Esempio n. 1
0
        public static AxMap GetAxMap()
        {
            if (_axMap1 != null)
            {
                return(_axMap1);
            }

            // Create MapWinGIS:
            _axMap1 = new AxMap();
            _axMap1.CreateControl();
            _axMap1.Width  = 200;
            _axMap1.Height = 200;

            // Create form and add MapWinGIS:
            var myForm = new Form();

            myForm.Controls.Add(_axMap1);

            _axMap1.ScalebarVisible   = true;
            _axMap1.ShowCoordinates   = tkCoordinatesDisplay.cdmAuto;
            _axMap1.ShowRedrawTime    = true;
            _axMap1.ShowVersionNumber = true;
            _axMap1.ShowZoomBar       = true;
            _axMap1.CursorMode        = tkCursorMode.cmZoomIn;

            return(_axMap1);
        }
Esempio n. 2
0
        public void Init()
        {
            // Create MapWinGIS:
            axMap1 = new AxMap();
            axMap1.CreateControl();

            // Create form and add MapWinGIS:
            myForm = new Form();
            myForm.Controls.Add(axMap1);

            axMap1.Projection        = tkMapProjection.PROJECTION_WGS84;
            axMap1.KnownExtents      = tkKnownExtents.keLatvia;
            axMap1.ScalebarVisible   = true;
            axMap1.ShowCoordinates   = tkCoordinatesDisplay.cdmAuto;
            axMap1.ShowRedrawTime    = true;
            axMap1.ShowVersionNumber = true;
            axMap1.ShowZoomBar       = true;

            CreateLayer();
        }