Código:
<form id="pol" name="listpol" method="post" action=""> <p style="margin:0"> <% dim conex, rs dim cnt set conex = Server.CreateObject("ADODB.Connection") conex.open = "driver={SQL Server};server=TAU; database=Canal; uid=sa;pwd=pasword" 'response.Write("se conecto") Set rs = Server.CreateObject ("ADODB.RecordSet") temp = "SELECT DISTINCT pv_header.nro_pol AS Poliza, tramo.txt_desc AS Ramo FROM maseg_header INNER JOIN pv_header ON maseg_header.cod_aseg = pv_header.cod_aseg INNER JOIN tramo ON pv_header.cod_ramo = tramo.cod_ramo WHERE (maseg_header.txt_nombre ='"& asegurado & "')" rs.open temp, conex%> <table width="60%" border="1" align="center" bordercolor="#808080"> <tr> <th width="7%" class="tabla_enc"> </th> <th width="44%" class="tabla_enc"> Número Poliza </th> <th width="49%" class="tabla_enc"> Ramo </th> </tr> <% while not rs.EOF poliza= rs.fields("poliza") ramo = rs.fields("Ramo") %> <tr> <td class="tabla_cont"><input type="radio" name="radio" id="ra1" value="ra1" /> td> <td class="tabla_cont"><%response.write(poliza)%></td> <td class="tabla_cont"> <%response.write(ramo)%> </td> </tr> <% rs.movenext wend rs.close conex.close set rs = nothing set conex = nothing %></table> </p> <p style="margin:0"> </p> <label> <input type="submit" name="selpol" id="selpol" value="Enviar" /> </label> </form> <p style="margin:0"> </p>