Arama butonu
Bu konudaki kullanıcılar: 1 misafir, 1 mobil kullanıcı
0
Cevap
525
Tıklama
0
Öne Çıkarma
asp combobox sorunum
N
11 yıl
Çavuş
Konu Sahibi

combobox ta seçilen değere göre mysql daki verileri listeletmek istiyorum.ancak aşağıdaki hatayı alıyorum.

Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
[MySQL][ODBC 3.51 Driver][mysqld-5.5.34-32.0]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
/Default.asp, line 59

kodlarım şu:


<div id="anket_ana">
<%
Set anket_sorusu = mySQL.Execute("Select * from anket_soru ")
If anket_sorusu.eof then soru = 0 Else soru = anket_sorusu("sira")
ip = Request.ServerVariables("REMOTE_ADDR")
Set ip_kontrol = mySQL.Execute("Select soru,ip from anket_oylandi where soru = '"&anket_sorusu("sira")&"' and ip = '"&ip&"'")
If ip_kontrol.eof then

%>


<div id="anket_soru">
<select name="select" >
<% While (Not anket_sorusu.EOF) %>
<option value="<%=anket_sorusu("sira")%>"><%=anket_sorusu("soru")%></option>

<%
anket_sorusu.MoveNext()
Wend
If (anket_sorusu.CursorType > 0) Then
anket_sorusu.MoveFirst
Else
anket_sorusu.Requery
End If
%>
</select>
<%
Do while (not anket_sorusu.EOF)
anket_sorusu.MoveNext
Loop
%>
<%
anket_sorusu.Close
Set anket_sorusu = Nothing

%>
<%


Set anket_cevap = mySQL.Execute("Select * from anket_cevap where soru = "&sira&" ")
If not anket_cevap.eof then
Do while not anket_cevap.eof
response.write "<input type=""radio"" name=""oy"" id=""oy"" class=""radio"" value="""&anket_cevap("sira")&"""><label>"&anket_cevap("cevap")&"</label><br />"
anket_cevap.movenext
Loop
response.write "<input type=""button"" value=""Oy Ver"" class=""button"" onclick=""simdi_oyla();"" />"

End If
%>
</div>
<div id="anket_cevap"></div>
<%
Else
%>
<div id="anket_durum">
<%
response.write "<h3>"&anket_sorusu("soru")&"</h3>"
Set oy_ortalamasi = mySQL.Execute("Select sum(oy) from anket_cevap where soru = '"&anket_sorusu("sira")&"'")
yuzde_ortalama = CInt(oy_ortalamasi(0)) / 100
oy_ortalamasi.close
Set yayin_cevap = mySQL.Execute("Select * from anket_cevap ")
Do while not yayin_cevap.eof
response.write "<div style=""float: left; width: 100px;""><h3>"&yayin_cevap("cevap")&"</h3></div><div style=""float: left;margin: 11px 0px 2px 0px;""><img src=""sol.png"" /><img src=""orta.png"" class=""renklendir"" style=""width:"&round(yayin_cevap("oy")/yuzde_ortalama,0)&"px;"" /><img src=""sag.png"" /></div>"
response.write "<div style=""clear: both;""></div>"
yayin_cevap.movenext
Loop
yayin_cevap.close
%>
</div>
<%
End If
%>
</div>


anket sorularımı comboboxta görüyorum.ancak soruyu secince hemen altında o anketin soruları çıksın istiyorum.Yardım ederseniz sevinirim.



DH Mobil uygulaması ile devam edin. Mobil tarayıcınız ile mümkün olanların yanı sıra, birçok yeni ve faydalı özelliğe erişin. Gizle ve güncelleme çıkana kadar tekrar gösterme.