private static int GetMovieID(string MovieName) { int MovieID = 0; OleDbCommand com = new OleDbCommand("SELECT * FROM movies WHERE [movieName]='" + MovieName + "'",cn); OleDbDataReader dr = com.ExecuteReader(); while (dr.Read()) { MovieID = (int)dr["ID"]; } return MovieID; }
cn.Open();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)