it looks like you are mixing up server side and client side javacsript.
To fill up an array in client side
JS with data from your database, you would do something like this:
Code:
<script language="javascript">
//opening an array
var MyArray = new Array();
//now we go server side to get the data from the db
<%
while (rs.EOF == false)
{
%>
//now going back client side
//let say than the index of your array will be the id from your db
//and the value of your array will be the names
//using <%= replaces your response.Write, you only use Response.Write to write on the page, not to pass a value
MyArray[<%= rs("id").Value %>] = <%= rs("name").Value %>;
<%
//now we go back server side to keep looping
//then we move to the next record
rs.MoveNext();
}
%>
</script>
This will store all values from your db into your array
Hope this helps