void radListControl1_ItemDataBound(object sender, ListItemDataBoundEventArgs args) { PaletteListDataItem listDataItem = (PaletteListDataItem)args.NewItem; PaletteObject dataObject = (PaletteObject)listDataItem.DataBoundItem; listDataItem.Palette = dataObject.Palette; }
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; }
private void radComboDemo_ItemDataBound(object sender, ListItemDataBoundEventArgs e) { RadListDataItem item = e.NewItem; item.Text += " " + (item.DataBoundItem as DataRowView)["FirstName"]; Telerik.Examples.WinControls.DataSources.NorthwindDataSet.EmployeesRow row = (item.DataBoundItem as DataRowView).Row as Telerik.Examples.WinControls.DataSources.NorthwindDataSet.EmployeesRow; item.Image = GetImageFromData(row.Photo); item.Font = new Font("Arial", 10, FontStyle.Bold); }
void cmbArtist_ItemDataBound(object sender, ListItemDataBoundEventArgs args) { RadListDataItem item = args.NewItem; object dataBoundItem = item.DataBoundItem; item.TextImageRelation = TextImageRelation.ImageBeforeText; PropertyDescriptor desc = TypeDescriptor.GetProperties(dataBoundItem).Find("ImageIndex", false); item.Image = this.cmbArtist.ImageList.Images[(int)desc.GetValue(dataBoundItem)]; }
private void listPhotos_ItemDataBound(object sender, ListItemDataBoundEventArgs args) { args.NewItem.Height = 126; }
private void radComboDemo_ItemDataBound(object sender, ListItemDataBoundEventArgs args) { args.NewItem.Image = ((DataItem)args.NewItem.DataBoundItem).Image; args.NewItem.TextImageRelation = TextImageRelation.ImageBeforeText; }
private void listVisits_ItemDataBound(object sender, ListItemDataBoundEventArgs args) { args.NewItem.Height = 100; }