예제 #1
0
        public ActionResult Index2(string IP, int port, int rate)
        {
            var location = new LocationSampler(IP, port).GetCurrentInfo();

            ViewBag.lon  = location.Lon;
            ViewBag.lat  = location.Lat;
            ViewBag.rate = rate;
            return(View());
        }
예제 #2
0
        public ActionResult Index1(int IP1, int IP2, int IP3, int IP4, int port)
        {
            string IP       = IP1 + "." + IP2 + "." + IP3 + "." + IP4;
            var    location = new LocationSampler(IP, port).GetCurrentInfo();

            ViewBag.lon = location.Lon;
            ViewBag.lat = location.Lat;
            return(View());
        }
예제 #3
0
        public ActionResult Index3(string IP, int port, int rate, int length, string filename)
        {
            FileHandler fileHandler = new FileHandler();
            var         location    = new LocationSampler(IP, port).GetCurrentInfo();

            ViewBag.lon          = location.Lon;
            ViewBag.lat          = location.Lat;
            ViewBag.rate         = rate;
            ViewBag.length       = length;
            @Session["filename"] = filename;
            fileHandler.DeletFile(AppDomain.CurrentDomain.BaseDirectory + @"\" + Session["filename"] + ".txt");
            return(View());
        }