Ejemplo n.º 1
0
        public void loadMoviesGrid()
        {
            // create a data services object , load up the movies from db and destroy the object
            moviesdataServices ds = new moviesdataServices();

            ds.loadMovies(dataGridView1);
            ds = null;
        }
Ejemplo n.º 2
0
        private void button3_Click(object sender, EventArgs e)
        {
            SortedList dataList = new SortedList();

            dataList.Add("@mID", this.Movie.Text);

            moviesdataServices ds = new moviesdataServices();

            ds.deleteMovie(dataList);
            ds = null;

            loadMoviesGrid();
        }
Ejemplo n.º 3
0
        private void Button1_Click(object sender, EventArgs e)
        {
            //create a new list containing the data
            SortedList dataList = new SortedList();

            dataList.Add("@mID", this.Movie.Text);
            dataList.Add("@mMovieName", this.MovieName.Text);
            dataList.Add("@mMovieRating", this.MovieRating.Text);
            dataList.Add("@mMovieActors", this.MovieAct.Text);
            dataList.Add("@mMovieD", this.MovieD.Text);
            dataList.Add("@mMovieProductionDate", this.dateTimePicker1.Value);

            moviesdataServices ds = new moviesdataServices();

            ds.insertMovie(dataList);
            ds = null;

            loadMoviesGrid();
        }