ngambhava Posted May 8, 2006 Posted May 8, 2006 We have used one listbox in windows form and we bind it with datasource from database. Listbox allows multiple selected. How can we retrive value of selected items from the list box?? we tried following thing for(int i=0;i<lstEducation.SelectedItems.Count;i++) MessageBox.Show(lstEducation.SelectedItems.ToString()); But it prints System.Data.DataRowView We couldnt find the way please help Quote
Administrators PlausiblyDamp Posted May 8, 2006 Administrators Posted May 8, 2006 Each item is a DataRowView object based on the underlying data source - you need to cast it to a DataRowView and then you can access it's properties directly. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.