Solution: simple asp to aspx
<p>I had presented a question but it was pulled.</p>

<p>It's been two years since I coded and over 15 years since any web apps.</p>

<p>I had asked for the aspx version of some asp code.</p>

<p>I needed to do away with access ODBC jet and use the SQL server.</p>

<p>The two main lines I needed help with where:</p>

<pre><code>&lt;% set ors = server.createobject(“ADODB.Recordset”) %&gt;
</code></pre>

<p>And</p>

<pre><code>&lt;% ors.open  “selectstatment”, “FILEDSN=B.dsn” %&gt;
</code></pre>

<p>The answer I discovered:</p>

<p>First you need the library:
     &lt;%@import Namespace= “System.Data.SqlClient %></p>

<p>Then you can use:</p>

<pre><code>&lt;% using conn as new sqlconnection(connstring.ConnectionString) %&gt;
&lt;% dim command as new sqlCommand(sqlselectstatment, conn) %&gt;
</code></pre>

<p>and after a</p>

<pre><code>    &lt;% conn.Open() %&gt;
</code></pre>

<p>and </p>

<pre><code>    &lt;% dim reader as sqlDataReader = command.ExecuteReader() %&gt;
</code></pre>

<p>you can start reading data.</p>

<pre><code>    &lt;% reader.read %&gt;
</code></pre>

<p>and see the first field with</p>

<pre><code>    &lt;%=reader(0)%&gt;
</code></pre>

<p>The final write of the code is using masterpages, web.config and passing paramaters. The connection string is in web.config.</p>

<p>I hope that this gets through because I think it is a very simple solution to just filling a page of thumbnails.</p>

<p>Note: I was just using exprestion web but now I know that VS will supply the needed syntax help for the inline code. Even the help on exprestion web indicates the need for VS as part of the coding support. Don't limit yourself with just one tool.</p>

<pre><code>&lt;%@ Page language="vb" masterpagefile="~/masterpage.master" title="Brooches" %&gt;
&lt;%@ Import Namespace="System.Data.SqlClient" %&gt;
&lt;asp:Content id="Content1" runat="server" contentplaceholderid="Left"&gt;
&lt;img alt="Pages" src="Brooches-Page-numbers.jpg" style="width: auto"/&gt;
&lt;/asp:Content&gt;
&lt;asp:Content id="Content2" runat="server" contentplaceholderid="Main"&gt;
&lt;%  Dim rootWebConfig As System.Configuration.Configuration =     

System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration    ("~/sitename")
   Dim connString As System.Configuration.ConnectionStringSettings
   Dim sqlStmt As String = "select Ref from Inventory where     Catagory='Brooches'"
   Dim RecordCounter1 As Integer
   Dim StartRecord As Integer = Request("StartRecord")
   connString = rootWebConfig.ConnectionStrings.ConnectionStrings ("BruceoriaSQLConnectionString1")
   Using conn As New SqlConnection(connString.ConnectionString)
       Dim command As New SqlCommand(sqlStmt, conn)
       conn.Open()
       Dim reader As SqlDataReader = command.ExecuteReader() %&gt;
 &lt;% 
    For RecordCounter1 = StartRecord To StartRecord + 24
        If reader.Read Then %&gt;
  &lt;a href="DetailsFrame.asp?SelectedRecord=&lt;%=(RecordCounter1 + Request("StartRecord"))%&gt;"&gt;&lt;img border="0" width="100" 

height="75" src="images/&lt;%=reader(0)%&gt;tt.jpg" alt="Image"/&gt;&lt;/a&gt;

        &lt;% End If
        Next
        conn.Close()
    End Using%&gt;
&lt;/asp:Content&gt;
</code></pre>
