Connecting Tech Pros Worldwide Help | Site Map

CheckListBox

Newbie
 
Join Date: Mar 2008
Posts: 2
#1: May 7 '08
I'm new to VB.Net

Can anyone tell me what i done wrong ?

If clbSolar.SelectedIndex = True Then
lstSolar.Items.Add("5%")
Else
lstSolar.Items.Add("")
End If


on my listbox, it won't come out.
debasisdas's Avatar
Moderator
 
Join Date: Dec 2006
Location: Bangalore ,India
Posts: 7,497
#2: May 7 '08

re: CheckListBox


Does SelectedIndex returns a boolean value ?
Newbie
 
Join Date: Dec 2006
Posts: 20
#3: May 7 '08

re: CheckListBox


try this, should work
Expand|Select|Wrap|Line Numbers
  1. if checkedlistbox.getchecked(chekedlistbox.selectedindex) then
  2. ...
  3. end if
  4.  
Reply