class ABC { public string Name, Phone; public static IEnumerable<ABC> GetList() { List<ABC> foo = new List<ABC>(); //Some COde here return foo; } } Class A { private void GetList() { IEnumerable<ABC> abc = ABC.GetList(); foreach (ABC newitem in abc) { ListViewItem li = new ListViewItem(); li.Text = newitem.Name; li.Tag = newitem; //<<<<<<<<<<<<< Is this Possible ??? ListView1.Items.Add(li); } } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)