Ok,
I have found the code to retrieve the contents and column names from a MySql database in asp. (see the code below) What I am wondering, is if there is a way for the script page to find the size of database field so I can make the maxlength of a textbox equal to this value? Thanks in advance.
Set conn = Server.CreateObject("ADODB.Connection")
conn.open= "driver={MySQL ODBC 3.51 Driver};server=localhost;uid=user;pwd=pwd;database =myDb;Option=16387;"
mySql = "Select * From " & strTbl
set rsTbl = conn.Execute(mySql)
Response.Write "<table border=1>"
For Each Field in rsTbl.Fields
%>
<tr><td><% =Field.Name %></td><td><input type="text" name="<% =Field.Name %>" size="40" <% 'maxlength value from database field would go here %> ></td></tr>
<%
Next
Response.Write "</table><br>"