I'm trying to create a data transfer control between 2 radlist controls, but when I transfer/move/insert the new item, the value sets itself to null after adding the item, even though I've specified it.
Can anyone please tell me what I'm doing wrong?
My two radlists are lstLeft and lstRight. My code looks like this:
Telerik.WinControls.UI.RadListDataItem item = new Telerik.WinControls.UI.RadListDataItem(lstRight.SelectedItem.Text, new Guid(lstRight.SelectedItem.Value.ToString()));
lstLeft.Items.Add(item);
lstRight.Items.Remove(lstRight.SelectedItem);
lstLeft.Refresh();
lstRight.Refresh();
when I set a break point on "lstRight.Items.Remove(lstRight.SelectedItem);" the value for the item added in lstLeft is null. But if I check the value after creating the item, the value is there.
Help!
Can anyone please tell me what I'm doing wrong?
My two radlists are lstLeft and lstRight. My code looks like this:
Telerik.WinControls.UI.RadListDataItem item = new Telerik.WinControls.UI.RadListDataItem(lstRight.SelectedItem.Text, new Guid(lstRight.SelectedItem.Value.ToString()));
lstLeft.Items.Add(item);
lstRight.Items.Remove(lstRight.SelectedItem);
lstLeft.Refresh();
lstRight.Refresh();
when I set a break point on "lstRight.Items.Remove(lstRight.SelectedItem);" the value for the item added in lstLeft is null. But if I check the value after creating the item, the value is there.
Help!