voila, je cre une liste deroulante avec un champ nommé "INSEE" puis j'affiche l'enregstrement dans un tableau en fonction de ce champ seulement ca plante ! le navigateur cherche un moment puis plante aprés la sélection du champ "INSEE".
voila le code: je c plus quoi faire !!!
Code : Sélectionner tout - Visualiser dans une fenêtre à part
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82 <!-- Connexion à la base de données --> <% Set conn = Server.CreateObject("ADODB.Connection") conn.open "Driver={Microsoft ACCESS Driver (*.mdb)}; DBQ=" & Server.MapPath("regroupement.mdb") on error resume next %> <HTML> <HEAD> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"> <LINK REL="stylesheet" HREF="css/style.css" TYPE="text/css"> <TITLE>Dossiers CU PC LT</TITLE> </HEAD> <BODY> <div align="center"> <font color="#990000"><div align="center"><font size="+2"><b>Dossiers CU PC LT</b></font></div></font> <br><br> <%if request.form("") = "" then %> <form action="dqf_CUPC.asp" target="droite" method="post"> <!-- Liste déroulante --> <TABLE border="1" bordercolordark="#66CC00"> <tr> <td>Code INSEE:<td> <td><%SQLQuery = "SELECT INSEE FROM Dossiers_CUPCLT" Set RS = conn.Execute(SQLQuery)%> <select name="INSEE" size=""> <option value=none>***</option> <% Do While Not RS.EOF %> <option value="<%= RS("INSEE")%>"><%= RS("INSEE")%></option> <%RS.MoveNext Loop%> <%rs.close%> <input type="submit" value="Recherche"> </select> </td> </tr> </TABLE> <!-- Récupération des infos --> </form> <%end if%> <%if request.form("INSEE") <> "" then %> <h3>Code INSEE : <%SQLQuery = "SELECT INSEE FROM Dossiers_CUPCLT = " & request.form("INSEE") & "" Set RS = conn.Execute(SQLQuery)%> <% =rs("INSEE") %></h3> <BR><br> <%if rs.recordcount<>0 then%> <!-- Tableau de présentation --> <TABLE border="1" bordercolordark="#66CC00"> <THEAD> <TR> <TH>N° Dossier DQF</TH> <TH>Type de dossier</TH> <TH>Date de réception</TH> <TH>Agent DQF</TH> <TH>Numero de dossier</TH> </TR> </THEAD> <% On Error Resume Next rs.MoveFirst do while Not rs.eof%> <TR> <TD><%=rs("N° dossier DQF")%></TD> <TD><%=rs("Type Dossier")%></TD> <TD><%=rs("Date de réception")%></TD> <TD><%=rs("Agent DQF")%></TD> <TD><%=rs("N° Dossier")%></TD> </TR> <% rs.MoveNext loop%> </TABLE> <%end if%> <%end if%> </div> </BODY> </HTML>
Partager