Re: Problem CheckedListBox
list_cc is obviously your groupbox + not your CheckedListBox
use the right name + it'll work
Re: Problem CheckedListBox
Thanks but have you a example , i don't understand
Re: Problem CheckedListBox
it's basic beginners vb. if you don't understand you should try a tutorial first:
http://www.homeandlearn.co.uk/NET/vbNet.html
Re: Problem CheckedListBox
Yes but my CheckedListBox's name is list_cc . And i want a fonction in CheckedListBox = Items or SelectedItem'
Re: Problem CheckedListBox
i can't give you an example because it really isn't clear what you're trying to do.
if you want to upload your project i'll have a look
Re: Problem CheckedListBox
Yes i want a example please . It's clear but i don't see how do .
Re: Problem CheckedListBox
please read post #6 again
i said i can't give you an example
Re: Problem CheckedListBox
Sorry but for my code :
How i can do now ?
Re: Problem CheckedListBox
Re: Problem CheckedListBox
This is my code for error error 'SelectedItem' :
VB Code:
If Not Me.list_cc.SelectedItem Is Nothing Then
'Retrouve le film avec ce nom
For Each ccALister As ccinfo In _Listecc
If ccALister.Nom = Me.list_cc.SelectedItem.ToString Then
'L'insère dans une variable globale
Me._ccEnVisualisation = ccALister
End If
Next
End If
This is my code for error error 'Item' :
My code is too long for post
Re: Problem CheckedListBox
i think we have a language barrier.
we need to see the relevant code if you have any chance of help + if it's all in french, i probably won't be able to help you
Re: Problem CheckedListBox
Code in english :
Vb Code:
If Not Me.list_cc.SelectedItem Is Nothing Then
'Found the movie with that name
For Each ccALister As ccinfo In _Listecc
If ccALister.Nom = Me.list_cc.SelectedItem.ToString Then
'Inserts in a global variable
Me._ccEnVisualisation = ccALister
End If
Next
End If
Re: Problem CheckedListBox
that isn't the relevant code
we need to see the lines that are causing the errors
Re: Problem CheckedListBox
also if vb says list_cc is a groupbox it probably is a groupbox
Re: Problem CheckedListBox
It's the only code for error SelectedItem
Vb Code:
If Not Me.list_cc.SelectedItem Is Nothing Then
'Found the movie with that name
For Each ccALister As ccinfo In _Listecc
If ccALister.Nom = Me.list_cc.SelectedItem.ToString Then
'Inserts in a global variable
Me._ccEnVisualisation = ccALister
End If
Next
End If
The rest is much too long for post . If you explain me the error , i can solve
the error for the rest of the code
Re: Problem CheckedListBox
in your form designer, click on the list_cc listbox(???) + take a screenshot that shows the selected listbox + the properties window + post it in this thread
Re: Problem CheckedListBox
Like paul said, unless you debug the code and locate the error, we won't be able to know the cause of error. You have something like " .Nom " in your code. What is it ?
Re: Problem CheckedListBox
Forget it, thank you but it's too complicated .. By cons how do I select all the boxes. I have this function but it does to selection:
CheckedListBox1.SetItemChecked (0, True)
Seconde question, I have fichier.vb [Design] but i have delet onglet , how I can to re-open this ?
Re: Problem CheckedListBox
i take it you solved the list_cc problem then?
vb Code:
For x As Integer = 0 To CheckedListBox1.Items.Count - 1
CheckedListBox1.SetItemChecked(x, True)
Next
Quote:
Originally Posted by
max1395
Seconde question, I have fichier.vb [Design] but i have delet onglet , how I can to re-open this ?
what's that in english?
Re: Problem CheckedListBox
I had a tab Fichier.vb [Design]. But without express I cancel tab, how to restore?
Re: Problem CheckedListBox
in your designer you have a project explorer window on the right. doubleclick Fichier.vb
Re: Problem CheckedListBox
Yes of course ^^ Thanks you . Sorry for my bad english .