Esempio n. 1
0
        private void ItemDataBound(object sender, ListItemDataBoundEventArgs args)
        {
            CustomListDataItem listDataItem = (CustomListDataItem)args.NewItem;
            BussinessObject    dataObject   = (BussinessObject)listDataItem.DataBoundItem;

            listDataItem.Name      = dataObject.Name;
            listDataItem.Available = dataObject.Available;
        }
Esempio n. 2
0
 private void CreateObjects()
 {
     for (int i = 0; i < NumberOfObjects; ++i)
     {
         BussinessObject businessObject = new BussinessObject();
         businessObject.Available = (i % 2) == 0;
         businessObject.Name      = " Item " + (i + 1);
         list[i] = businessObject;
         businessObject.PropertyChanged += new PropertyChangedEventHandler(businessObject_PropertyChanged);
     }
 }