Click here to Skip to main content
15,904,416 members
Home / Discussions / C#
   

C#

 
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 
AnswerRe: Windows Events Pin
Luc Pattyn16-Jan-07 8:26
sitebuilderLuc Pattyn16-Jan-07 8:26 
AnswerRe: Windows Events Pin
Dave Kreskowiak16-Jan-07 9:30
mveDave Kreskowiak16-Jan-07 9:30 
QuestionShowing two different printdocuments in single Print Preview dialog? Pin
kumar.bs16-Jan-07 8:08
kumar.bs16-Jan-07 8:08 
AnswerRe: Showing two different printdocuments in single Print Preview dialog? Pin
Luc Pattyn16-Jan-07 8:24
sitebuilderLuc Pattyn16-Jan-07 8:24 
GeneralRe: Showing two different printdocuments in single Print Preview dialog? Pin
kumar.bs16-Jan-07 9:15
kumar.bs16-Jan-07 9:15 
GeneralRe: Showing two different printdocuments in single Print Preview dialog? Pin
Luc Pattyn16-Jan-07 9:55
sitebuilderLuc Pattyn16-Jan-07 9:55 
GeneralRe: Showing two different printdocuments in single Print Preview dialog? Pin
kumar.bs16-Jan-07 12:52
kumar.bs16-Jan-07 12:52 
GeneralRe: Showing two different printdocuments in single Print Preview dialog? Pin
Luc Pattyn16-Jan-07 13:05
sitebuilderLuc Pattyn16-Jan-07 13:05 

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.