public Form1()
        {
            InitializeComponent();
            _context = new P112CourseEntities();

            //Demo();
        }
        // GET: Students
        public ActionResult Index()
        {
            P112CourseEntities db       = new P112CourseEntities();
            List <Student>     students = db.Students.OrderBy(s => s.Firstname).ToList();

            return(View(students));
        }
        public ActionResult Details(int?Id)
        {
            if (Id == null)
            {
                return(Content("Id null ola bilmez"));
            }

            P112CourseEntities db      = new P112CourseEntities();
            Student            student = db.Students.Find(Id);

            if (student == null)
            {
                return(HttpNotFound());
            }

            //Student student = new Student {
            //    Firstname = "Sattar",
            //    Lastname = "Amrahov",
            //    Email = "*****@*****.**",
            //    Birthdate = new DateTime(1992, 12, 6)
            //};
            return(View(student));
        }