Beispiel #1
0
 private void ActorsInMovieHandler()
 {
     MoviePeopleServices actors = new MoviePeopleServices();
     GridView actorsInMovie = new GridView();
     actorsInMovie = PeopleInMovie2.gridPeopleInMovie;
     int movieId = Convert.ToInt32(Request.QueryString["movieId"]);
     List<MoviePersonDTO> person;
     person = actors.GetMoviePeopleByMovieId(movieId, "Actor");
     if (person != null)
     {
         actorsInMovie.DataSource = person;
         actorsInMovie.DataBind();
         GetAppropriateView(actorsInMovie);
     }
     else
         return;
 }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                PeopleInMovie2.SetLabelText("Actors in " + "\"" + Request.QueryString["movieTitle"] + "\"" + " Movie");

            }
            MoviePeopleServices actors = new MoviePeopleServices();
            GridView actorsInMovie = new GridView();
            actorsInMovie = PeopleInMovie2.gridPeopleInMovie;
            int movieId = Convert.ToInt32(Request.QueryString["movieId"]);
            List<MoviePersonDTO> person;
            person = actors.GetMoviePeopleByMovieId(movieId, "Actor");
            if (person != null)
            {
                actorsInMovie.DataSource = person;
                actorsInMovie.DataBind();
                GetAppropriateView(actorsInMovie);
            }
               // actorsInMovie.DataSource = actors.GetMoviePeopleByMovieId(movieId, "Actor");
        }