// GET: DwfPlot
        public ActionResult Index(MapGuideViewerInputModel input)
        {
            MgSiteConnection conn = CreateConnection(input);
            MgMap map = new MgMap(conn);
            map.Open(input.MapName);

            MgPoint center = map.ViewCenter;
            MgCoordinate coord = center.Coordinate;

            DwfPlotViewModel vm = new DwfPlotViewModel()
            {
                MapName = input.MapName,
                Session = input.Session,
                Scale = map.GetViewScale(),
                X = coord.X,
                Y = coord.Y
            };

            return View(vm);
        }
Beispiel #2
0
        // GET: DwfPlot
        public ActionResult Index(MapGuideViewerInputModel input)
        {
            MgSiteConnection conn = CreateConnection(input);
            MgMap            map  = new MgMap(conn);

            map.Open(input.MapName);

            MgPoint      center = map.ViewCenter;
            MgCoordinate coord  = center.Coordinate;

            DwfPlotViewModel vm = new DwfPlotViewModel()
            {
                MapName = input.MapName,
                Session = input.Session,
                Scale   = map.GetViewScale(),
                X       = coord.X,
                Y       = coord.Y
            };

            return(View(vm));
        }