protected override void OnInitializeInRuntime() { base.OnInitializeInRuntime(); CBFDatabaseServices db = new CBFDatabaseServices(); IEnumerable <CBFModels> CBF = db.GetAllCBF(); foreach (var i in CBF) { i.Family = db.GetAllFamily(i); } CBFModel = CBF; }
private void GetData() { CBFDatabaseServices db = new CBFDatabaseServices(); ObservableCollection <CBFModels> CBF = db.GetAllCBF(); foreach (var i in CBF) { i.Family = db.GetAllFamily(i); } CBFModel = CBF; InsertDbTest insert = new InsertDbTest(); insert.CountNum(); count = insert.Count; }