Bonjour à tous,
Comment fait-on pour selectionner dans un listbox une ligne quelconque.
:?:?
Version imprimable
Bonjour à tous,
Comment fait-on pour selectionner dans un listbox une ligne quelconque.
:?:?
Bonjour,
un peu léger comme explication, j'ai presque envie de répondre "tu cliques dessus" mais soyons sérieux expliques un peu mieux
bonjour AMO05 le forum code
ps bonjour l' ami casefayere pas rafraichiCode:listbox1.ListIndex ='numero ligne
Bonjour,
J'ai ce code qui fonctionne au 2/3.
Je n'arrive pas faire fonctionner la dernière condition. :question::question::question:Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32 Private Sub CommandButton1_Click() If Suites.ListBox1.ListIndex = -1 And interventions.ListBox1.ListIndex = interventions.ListBox1.ListIndex Then Suites.ListBox1.ListIndex = interventions.ListBox1.ListIndex Call intervenir1 'fait appel à la procédure intervenir1 () Call suite_donner1 'fait appel à la procédure suite_donner1() Unload Suites Unload interventions Unload problematique agentdesc.Show Else If Suites.ListBox1.ListIndex = Suites.ListBox1.ListIndex Then Call suite_donner1 'fait appel à la procédure suite_donner1() Unload Suites Unload interventions Unload problematique agentdesc.Show Else If Suites.ListBox1.ListIndex = -1 And interventions.ListBox1.ListIndex = -1 Then Call agent 'fait appel à la procédure agent () Call intervenir 'fait appel à la procédure intervenir () Call suite_donner 'fait appel à la procédure suite_donner() Unload Suites Unload interventions Unload problematique agentdesc.Show End If End If End If End Sub
re, le forum si j ai compris!! avec si peu d' infos pas simple
Code:
1
2
3 If Suites.ListBox1 = "" And interventions.ListBox1 = "" Then agent: intervenir: suite_donner: End: agentdesc.Show End If
Il fallait juste mettre de l'ordre dans les conditions.
la 1ere condition est normalement la 3ème,
la 2eme est la 1ere
et la 2eme est la 3eme:scarymov::scarymov:
Merci tout de même pour vos réponses;);)Code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32 Private Sub CommandButton1_Click() If interventions.ListBox1.ListIndex = -1 And Suites.ListBox1.ListIndex = -1 Then Call agent 'fait appel à la procédure agent () Call intervenir 'fait appel à la procédure intervenir () Call suite_donner 'fait appel à la procédure suite_donner() Unload Suites Unload interventions Unload problematique Unload agentdesc agentdesc.Show Else If Suites.ListBox1.ListIndex = -1 And interventions.ListBox1.ListIndex = interventions.ListBox1.ListIndex Then Suites.ListBox1.ListIndex = interventions.ListBox1.ListIndex Call intervenir1 'fait appel à la procédure intervenir1 () Call suite_donner1 'fait appel à la procédure suite_donner1() Unload Suites Unload interventions Unload problematique agentdesc.Show Else If Suites.ListBox1.ListIndex = Suites.ListBox1.ListIndex Then Call suite_donner1 'fait appel à la procédure suite_donner1() Unload Suites Unload interventions Unload problematique agentdesc.Show End If End If End If End Sub