Click here to Skip to main content
15,920,801 members
Home / Discussions / C#
   

C#

 
GeneralRe: Reading Xml using XmlReader Pin
Patrick Klug16-Jan-07 17:02
Patrick Klug16-Jan-07 17:02 
GeneralRe: Reading Xml using XmlReader Pin
Christian Graus16-Jan-07 19:42
protectorChristian Graus16-Jan-07 19:42 
QuestionGDI+ Question Pin
Mike Hankey16-Jan-07 12:30
mveMike Hankey16-Jan-07 12:30 
QuestionPrinting Pin
Christopher Thornburg16-Jan-07 11:39
Christopher Thornburg16-Jan-07 11:39 
AnswerRe: Printing Pin
gnadeem16-Jan-07 13:00
gnadeem16-Jan-07 13:00 
QuestionC# UI Control to crop images Pin
njoaopg16-Jan-07 11:22
njoaopg16-Jan-07 11:22 
AnswerRe: C# UI Control to crop images Pin
Christian Graus16-Jan-07 13:03
protectorChristian Graus16-Jan-07 13:03 
GeneralRe: C# UI Control to crop images Pin
electriac16-Jan-07 23:58
electriac16-Jan-07 23:58 
GeneralRe: C# UI Control to crop images Pin
Christian Graus17-Jan-07 0:01
protectorChristian Graus17-Jan-07 0:01 
GeneralRe: C# UI Control to crop images Pin
electriac17-Jan-07 5:20
electriac17-Jan-07 5:20 
GeneralRe: C# UI Control to crop images Pin
electriac17-Jan-07 5:21
electriac17-Jan-07 5:21 
GeneralRe: C# UI Control to crop images Pin
njoaopg17-Jan-07 5:35
njoaopg17-Jan-07 5:35 
Questionhow to display time over form ? Pin
Software_Specialist16-Jan-07 11:20
Software_Specialist16-Jan-07 11:20 
AnswerRe: how to display time over form ? Pin
Guffa16-Jan-07 12:29
Guffa16-Jan-07 12:29 
QuestionDatagridview combobox Pin
john3416-Jan-07 10:48
john3416-Jan-07 10:48 
QuestionListbox selecteditems Pin
Drew McGhie16-Jan-07 9:49
Drew McGhie16-Jan-07 9:49 
I have a listbox(default except theat the selectionmode is "multisimple") that I'm populating dynamically through a BindingSource, with the display and value member set to the same column. On loading of the form, I need to set the initial selected value(s) to a previously-stored value. I declare a List<string> called toSelect and fill it with the correct values. My problem is actually taking those values and selecting the correct listbox item(s).
What I currently have is:
foreach (string s in toSelect)
{
   if (uxlbSuite.Items.Contains(s))
   {
      uxlbSuite.SelectedItems.Add(s);
   }
}

The problem is that uxlbSuite.Items.Contains(s) always returns false, and the uxlbSuite.SelectedItems.Add(s) doesn't actually do anything if I don't perform the if check. I think I'm accessing the SelectedItems list wrong, but I'm baffled as to the correct way, and advice would be greatly appreciated.
AnswerRe: Listbox selecteditems Pin
Luc Pattyn16-Jan-07 10:31
sitebuilderLuc Pattyn16-Jan-07 10:31 
GeneralRe: Listbox selecteditems Pin
Drew McGhie17-Jan-07 3:49
Drew McGhie17-Jan-07 3:49 
QuestionComboBox Problem Pin
Darren D16-Jan-07 8:33
Darren D16-Jan-07 8:33 
AnswerRe: ComboBox Problem Pin
Christian Graus16-Jan-07 9:09
protectorChristian Graus16-Jan-07 9:09 
GeneralRe: ComboBox Problem Pin
Darren D16-Jan-07 9:28
Darren D16-Jan-07 9:28 
GeneralRe: ComboBox Problem Pin
Dave Kreskowiak16-Jan-07 10:05
mveDave Kreskowiak16-Jan-07 10:05 
GeneralRe: ComboBox Problem Pin
Darren D16-Jan-07 10:15
Darren D16-Jan-07 10:15 
QuestionWindows Events Pin
Monin D.16-Jan-07 8:18
Monin D.16-Jan-07 8:18 
AnswerRe: Windows Events Pin
Christian Graus16-Jan-07 8:23
protectorChristian Graus16-Jan-07 8:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.