Exemple #1
0
        }    //end Load Regular Members

        public void LoadMembersInListView(ListView lv)
        {
            Member    e  = new Member();
            DataTable dt = new DataTable();

            dt = e.SELECT_ALL();
            if (dt != null)
            {
                int ctr = 1;
                foreach (DataRow r in dt.Rows)
                {
                    ListViewItem li = new ListViewItem();
                    li.Text = ctr.ToString();
                    li.SubItems.Add(r["memid"].ToString());
                    li.SubItems.Add(r["fullname"].ToString());
                    li.SubItems.Add(r["address"].ToString());
                    li.SubItems.Add(r["contactno"].ToString());

                    Member_Standing ms = new Member_Standing();
                    ms.memid = r["memid"].ToString();
                    li.SubItems.Add(ms.STANDING);
                    li.SubItems.Add(r["tinno"].ToString());

                    li.BackColor = (ms.STANDING == "MIGS") ? Color.GreenYellow : Color.Red;

                    lv.Items.Add(li);
                    ctr++;
                }
            }
        }    //end LoadMembersInListView
Exemple #2
0
        public void LoadMembers(ComboBox cbo)
        {
            Member    e  = new Member();
            DataTable dt = new DataTable();

            dt = e.SELECT_ALL();
            if (dt != null)
            {
                foreach (DataRow r in dt.Rows)
                {
                    cbo.Items.Add(r["fullname"] + "-" + r["memid"]);
                }
            }
        }
Exemple #3
0
        public void LoadMembersInListView(ListView lv)
        {
            Member e = new Member();
                DataTable dt = new DataTable();

                dt = e.SELECT_ALL();
                if (dt != null)
                {
                    int ctr=1;
                    foreach (DataRow r in dt.Rows)
                    {
                        ListViewItem li = new ListViewItem();
                        li.Text = ctr.ToString();
                        li.SubItems.Add(r["memid"].ToString());
                        li.SubItems.Add(r["fullname"].ToString());
                        li.SubItems.Add(r["address"].ToString());
                        li.SubItems.Add(r["contactno"].ToString());

                        Member_Standing ms = new Member_Standing();
                        ms.memid = r["memid"].ToString();
                        li.SubItems.Add(ms.STANDING);
                        li.SubItems.Add(r["tinno"].ToString());

                        li.BackColor = (ms.STANDING == "MIGS") ? Color.GreenYellow : Color.Red;

                        lv.Items.Add(li);
                        ctr++;

                    }
                }
        }
Exemple #4
0
        public void LoadMembers(ComboBox cbo)
        {
            Member e = new Member();
                DataTable dt = new DataTable();

                dt = e.SELECT_ALL();
                if (dt != null) {
                    foreach (DataRow r in dt.Rows) {
                        cbo.Items.Add(r["fullname"] + "-" + r["memid"]);
                    }
                }
        }