Esempio n. 1
0
 public ConferencePrograms GetByID(int _conferenceProgramId)
 {
     ConferenceProgramsDAC _conferenceProgramsComponent = new ConferenceProgramsDAC();
      IDataReader reader = _conferenceProgramsComponent.GetByIDConferencePrograms(_conferenceProgramId);
      ConferencePrograms _conferencePrograms = null;
      while(reader.Read())
      {
          _conferencePrograms = new ConferencePrograms();
          if(reader["ConferenceProgramId"] != DBNull.Value)
              _conferencePrograms.ConferenceProgramId = Convert.ToInt32(reader["ConferenceProgramId"]);
          if(reader["ProgramName"] != DBNull.Value)
              _conferencePrograms.ProgramName = Convert.ToString(reader["ProgramName"]);
          if(reader["ConferenceId"] != DBNull.Value)
              _conferencePrograms.ConferenceId = Convert.ToInt32(reader["ConferenceId"]);
      _conferencePrograms.NewRecord = false;             }             reader.Close();
      return _conferencePrograms;
 }
Esempio n. 2
0
 public List<ConferencePrograms> GetAllByConferenceId(int ConferenceId)
 {
     ConferenceProgramsDAC _conferenceProgramsComponent = new ConferenceProgramsDAC();
     IDataReader reader = _conferenceProgramsComponent.GetAllConferencePrograms("ConferenceId = " + ConferenceId).CreateDataReader();
     List<ConferencePrograms> _conferenceProgramsList = new List<ConferencePrograms>();
     while (reader.Read())
     {
         if (_conferenceProgramsList == null)
             _conferenceProgramsList = new List<ConferencePrograms>();
         ConferencePrograms _conferencePrograms = new ConferencePrograms();
         if (reader["ConferenceProgramId"] != DBNull.Value)
             _conferencePrograms.ConferenceProgramId = Convert.ToInt32(reader["ConferenceProgramId"]);
         if (reader["ProgramName"] != DBNull.Value)
             _conferencePrograms.ProgramName = Convert.ToString(reader["ProgramName"]);
         if (reader["ConferenceId"] != DBNull.Value)
             _conferencePrograms.ConferenceId = Convert.ToInt32(reader["ConferenceId"]);
         _conferencePrograms.NewRecord = false;
         _conferenceProgramsList.Add(_conferencePrograms);
     } reader.Close();
     return _conferenceProgramsList;
 }
Esempio n. 3
0
 public bool Insert(ConferencePrograms conferenceprograms)
 {
     int autonumber = 0;
     ConferenceProgramsDAC conferenceprogramsComponent = new ConferenceProgramsDAC();
     bool endedSuccessfuly = conferenceprogramsComponent.InsertNewConferencePrograms( ref autonumber,  conferenceprograms.ProgramName,  conferenceprograms.ConferenceId);
     if(endedSuccessfuly)
     {
         conferenceprograms.ConferenceProgramId = autonumber;
     }
     return endedSuccessfuly;
 }
Esempio n. 4
0
 public void Delete(int Original_ConferenceProgramId)
 {
     ConferenceProgramsDAC conferenceprogramsComponent = new ConferenceProgramsDAC();
     conferenceprogramsComponent.DeleteConferencePrograms(Original_ConferenceProgramId);
 }
Esempio n. 5
0
 public int UpdateDataset(System.Data.DataSet dataset)
 {
     ConferenceProgramsDAC conferenceprogramscomponent = new ConferenceProgramsDAC();
     return conferenceprogramscomponent.UpdateDataset(dataset);
 }
Esempio n. 6
0
 public bool Update( string ProgramName,  int ConferenceId,  int Original_ConferenceProgramId)
 {
     ConferenceProgramsDAC conferenceprogramsComponent = new ConferenceProgramsDAC();
     return conferenceprogramsComponent.UpdateConferencePrograms( ProgramName,  ConferenceId,  Original_ConferenceProgramId);
 }
Esempio n. 7
0
 public bool Update(ConferencePrograms conferenceprograms ,int old_conferenceProgramId)
 {
     ConferenceProgramsDAC conferenceprogramsComponent = new ConferenceProgramsDAC();
     return conferenceprogramsComponent.UpdateConferencePrograms( conferenceprograms.ProgramName,  conferenceprograms.ConferenceId,  old_conferenceProgramId);
 }
Esempio n. 8
0
        public bool Insert( string ProgramName,  int ConferenceId)
        {
            ConferenceProgramsDAC conferenceprogramsComponent = new ConferenceProgramsDAC();
            int ConferenceProgramId = 0;

            return conferenceprogramsComponent.InsertNewConferencePrograms( ref ConferenceProgramId,  ProgramName,  ConferenceId);
        }