
Fill drop-down menu with elements of Dbase
In Jscript, I made the following code to fill a drop-down menu with the
elements of the database called " country ". Since we are starting with
SiteServer, in which everything is programmed in VB, and since I'm not
fimiliar at all with this p-language, I was hoping that someone could give
me the "VB-translation" of the following code:
<%
strSQL = "SELECT DISTINCT(country) FROM country ORDER BY country";
arrSQL = cn.Execute(strSQL);
s = "";
for (; !arrSQL.EOF; arrSQL.MoveNext())
{
if (strTITLE==arrSQL(0).value)
s += '<option selected value="' + arrSQL(0) + '">'
else
s += '<option value="' + arrSQL(0) + '">';
s += arrSQL(0).value;
s += '\n';
}
Response.Write(s);
%>
I thank everyone in advance who is willing to spend his time on this
question. With Regards,
Dennis Sprengers