コード例 #1
0
        private void bw2_DoWork(object sender, DoWorkEventArgs e)
        {
            lst.Controls.Clear();

            foreach (FileItem F in myFiles.Where(s => s.displayName.ToLower().Contains(txtSearch.Text.ToLower())))
            {
                fItem itm = new fItem();
                itm.NameProperty = F.displayName;
                //itm.setIcon(F.icn);
                itm.setFileItem(F);
                lst.Controls.Add(itm);
            }
        }
コード例 #2
0
        //Show all files in listview

        public void renderFiles()
        {
            //remove first all items:

            lst.Controls.Clear();

            foreach (FileItem F in myFiles.Where(s => s.displayName.ToLower().Contains(txtSearch.Text.ToLower())))
            {
                fItem itm = new fItem();
                itm.NameProperty = F.displayName;
                //itm.setIcon(F.icn);
                itm.setFileItem(F);
                lst.Controls.Add(itm);
            }
        }