Esempio n. 1
0
 public virtual ActiveElectionCycleTds.ActiveElectionCyclesDataTable GetData(string candidateID)
 {
     this.Adapter.SelectCommand = this.CommandCollection[0];
     if ((candidateID == null))
     {
         this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
     }
     else
     {
         this.Adapter.SelectCommand.Parameters[1].Value = ((string)(candidateID));
     }
     ActiveElectionCycleTds.ActiveElectionCyclesDataTable dataTable = new ActiveElectionCycleTds.ActiveElectionCyclesDataTable();
     this.Adapter.Fill(dataTable);
     return(dataTable);
 }
Esempio n. 2
0
        public virtual int Fill(ActiveElectionCycleTds.ActiveElectionCyclesDataTable dataTable, string candidateID)
        {
            this.Adapter.SelectCommand = this.CommandCollection[0];
            if ((candidateID == null))
            {
                this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
            }
            else
            {
                this.Adapter.SelectCommand.Parameters[1].Value = ((string)(candidateID));
            }
            if ((this.ClearBeforeFill == true))
            {
                dataTable.Clear();
            }
            int returnValue = this.Adapter.Fill(dataTable);

            return(returnValue);
        }