Bonjour,
Je veux afficher une liste déroulante des numéros dynamique(1,2,...)
dans jsp:
et dans l'Action:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10 <tr> <td align="right" width="50%"><b>Num d'affichage:<font color="#FF0000">*</font></b></td> <td colspan="3" align="left" width="50%"> <html:select property="available" indexed="i" > <html:option key="" value="" /> <html:optionsCollection name="numeros" value="i" /> </html:select> </td> </tr>
Comment remplir le champ value="" pour qu'il prend la valeur numérique séléctionnée
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10 List<Long> numeros = new ArrayList<Long>(); numeros.add((long) 1); numeros.add((long) 2); numeros.add((long) 3); numeros.add((long) 4); numeros.add((long) 5); numeros.add((long) 6); objForm.setNumeros(numeros); request.getSession(true).setAttribute("numeros",numeros);
Merci d'avance
Partager