Exemple #1
0
 /// <summary>
 /// Creates an instance of the class
 /// </summary>
 /// <param name="parent">associated context</param>
 /// <param name="dataSource">origin table</param>
 public AccessContextList(AccessContext parent, RootList dataSource)
 {
     Parent      = parent;
     DataSource  = dataSource;
     ItemManager = new AccessContextListItemManager(this);
     ResetLocalData();
 }
Exemple #2
0
        private void buttonSimulateDatabaseAction_Click(object sender, EventArgs e)
        {
            DataLayer.RootList tableProducts = DataHost.Tables["Products"];

            tableProducts[0].SetValue("Name", "ChangedName");

            tableProducts.Remove(tableProducts[1]);
            tableProducts.Remove(tableProducts[1]);

            DataLayer.RootItem item1 = tableProducts.AddNew();
            item1.SetValue("Name", "NewProduct1");

            DataLayer.RootItem item2 = tableProducts.AddNew();
            item2.SetValue("Name", "NewProduct2");

            DataLayer.RootItem item3 = tableProducts.AddNew();
            item3.SetValue("Name", "NewProduct3");
        }
Exemple #3
0
 public RootListDefinition(string tableName)
 {
     Name       = tableName;
     List       = new List <AccessContext>();
     DataSource = new RootList(tableName);
 }