public RoutineDataViewModel() { BLPlanned bl = new BLPlanned(); var list = new List <RoutineShow>(); list = bl.RoutineShowSend(); foreach (var item in list) { routines.Add(item); } //routines.Add(new RoutineShow() { RoutineName = "Hina", ExcerciseName = "Cable Crunch" }); //routines.Add(new RoutineShow() { RoutineName = "Ayushi", ExcerciseName = "Zumba" }); //routines.Add(new RoutineShow() { RoutineName = "Swathy", ExcerciseName = "Aerobics" }); }
void onBackClick(object sender, System.EventArgs e) { //Dao.GetMyExercises.Clear(); RoutineShow rs = new RoutineShow(); List <RoutineShow> rsList = new List <RoutineShow>(); ObservableCollection <RoutineShow> allEx = Dao.GetMyExercises; for (int i = 0; i < allEx.Count; i++) { rs.RoutineName = entry_routine.Text; rs.ExcerciseName = allEx[i].ExcerciseName; rsList.Add(rs); } BLPlanned bLPlanned = new BLPlanned(); int rowInserted = bLPlanned.RoutineShowInsert(rsList); RoutineDataViewModel rdvm = new RoutineDataViewModel(); App.Current.MainPage.Navigation.PopModalAsync(); }