public ActionResult DeleteConfirmed(int id)
        {
            SimulatedBu simulatedBus = db.SimulatedBus.Find(id);

            db.SimulatedBus.Remove(simulatedBus);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
        public ActionResult Create([Bind(Include = "Id,LastCheckin,Measurement_Timestamp,BusId")] SimulatedBu simulatedBus)
        {
            if (ModelState.IsValid)
            {
                db.SimulatedBus.Add(simulatedBus);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            ViewBag.BusId = new SelectList(db.Buses, "BusId", "BusName", simulatedBus.BusId);
            return(View(simulatedBus));
        }
        // GET: SimulatedBus/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            SimulatedBu simulatedBus = db.SimulatedBus.Find(id);

            if (simulatedBus == null)
            {
                return(HttpNotFound());
            }
            return(View(simulatedBus));
        }
        // GET: SimulatedBus/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            SimulatedBu simulatedBus = db.SimulatedBus.Find(id);

            if (simulatedBus == null)
            {
                return(HttpNotFound());
            }
            ViewBag.BusId = new SelectList(db.Buses, "BusId", "BusName", simulatedBus.BusId);
            return(View(simulatedBus));
        }