Click here to Skip to main content
15,667,475 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
I insert data using combo boxes. but the problem is i can only insert data in monday .it is not moving forward it is insert data into monday's loop again and again.
private void Button_Click_1(object sender, RoutedEventArgs e)

            try {
                //var cmb1 = cmbMon2.SelectedItem as ComboBoxItem;

                //var cmb2 = cmbMon3.SelectedItem as ComboBoxItem;

                //var cmb3 = cmbMon4.SelectedItem as ComboBoxItem;

                //var cmb4 = cmbMon5.SelectedItem as ComboBoxItem;

                //var cmb5 = cmbMon6.SelectedItem as ComboBoxItem;

                var db = new SQLite.SQLiteConnection(App.DBPath);
                tt t1 = new tt();
                tt t2 = new tt();
                tt t3 = new tt();

                for (int i = 0; i < monday.Count; i++)

                    t1.Monday = monday[i].ToString();

                for(int i=0;i<tuesday.count;i++)>
                    t2.Tuesday = tuesday[i].ToString();

                for (int i = 0; i < wednesday.Count;i++ )
                    t3.Wednesday = wednesday[i].ToString();

            catch(Exception ex)
Updated 21-Apr-15 5:02am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900