示例#1
0
        public override bool Load()
        {
            bool ret = true;

            try
            {
                if (Common.Conn == null)
                {
                    Common.Conn = new SQLiteConnection(Common.ConnectionString);
                    Common.Conn.Open();
                }
                SQLiteDataReader myReader  = null;
                SQLiteCommand    myCommand = new SQLiteCommand();


                myReader = null;
                myCommand.CommandText = @"SELECT * FROM [tblEWSUser] ";
                myCommand.Connection  = Common.Conn;
                myReader = myCommand.ExecuteReader();
                while (myReader.Read())
                {
                    tblEWSUser tblewsuser = new tblEWSUser();
                    tblewsuser.m_SolutionID_tblSolution = this.m_SolutionID_tblSolution;
                    tblewsuser.AddFromRecordSet(myReader);
                    this.Add(tblewsuser);
                }

                myReader.Close();
                myCommand.Dispose();
            }
            catch (SQLiteException ae)
            {
                System.Windows.Forms.MessageBox.Show(ae.Message);
                return(false);
            }



            return(ret);
        }
示例#2
0
 public bool Contains(tblEWSUser item)
 {
     return(List.Contains(item));
 }
示例#3
0
 public int IndexOf(tblEWSUser item)
 {
     return(List.IndexOf(item));
 }
示例#4
0
 public void Insert(int index, tblEWSUser item)
 {
     List.Insert(index, item);
     this.OntblEWSUserChanged(EventArgs.Empty);
 }
示例#5
0
 public void Remove(tblEWSUser item)
 {
     List.Remove(item);
     this.OntblEWSUserChanged(EventArgs.Empty);
 }
示例#6
0
 public void Add(tblEWSUser item)
 {
     List.Add(item);
     this.OntblEWSUserChanged(EventArgs.Empty);
 }