E
egsdar
Hello, I have a code that I did in ASP and need to migrate to ASP.Net. This
is my code in ASP 3.0:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<%
set conn=server.CreateObject ("ADODB.connection")
conn.Open ("Driver={MySQL ODBC 3.51
Driver};SERVER=localhost;DATABASE=proyectos;UID=root;PWD=4116734")
set Rs1=server.CreateObject ("ADODB.Recordset")
set Rs2=server.CreateObject ("ADODB.Recordset")
sql1="select * from modasg,modulos where modasg.cod="&session("codigo")&"
and modulos.cod=modasg.codmodulo group by modulos.padre order by codmodulo"
set rs1=conn.execute(sql1)
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="Micss.css" rel="stylesheet" type="text/css">
</head>
<body background="Images/fondo_Menu.gif" id="fondo" leftmargin="0">
<p>
<table width="10" border="0" cellspacing="0" style="width:150px;">
<%while not rs1.eof%>
<tr>
<td><img src="<%=rs1("imagen")%>"></td>
</tr>
<%sql2="select * from modasg,modulos where
modasg.cod="&session("codigo")&" and modulos.cod=modasg.codmodulo and
modulos.padre="&rs1("padre")&" order by codmodulo"
set rs2=conn.execute(sql2)
while not rs2.eof%>
<tr><td onMouseOver="this.style.color='#ff9900';"
onMouseOut="this.style.color='#000000';" style="cursor:hand"><div
align="left"><strong>
<font face="MS Sans Serif" size="1"><a
href="<%response.Write(rs2("modulo")+".asp")%>" target="mainFrame">
<%response.Write(""+rs2("modulo")+"")%>
</a></font></strong></div></tr></td>
<%
rs2.movenext
wend
rs1.movenext
wend%>
</table>
<p><br>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
</body>
</html>
can u help me with this?
is my code in ASP 3.0:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<%
set conn=server.CreateObject ("ADODB.connection")
conn.Open ("Driver={MySQL ODBC 3.51
Driver};SERVER=localhost;DATABASE=proyectos;UID=root;PWD=4116734")
set Rs1=server.CreateObject ("ADODB.Recordset")
set Rs2=server.CreateObject ("ADODB.Recordset")
sql1="select * from modasg,modulos where modasg.cod="&session("codigo")&"
and modulos.cod=modasg.codmodulo group by modulos.padre order by codmodulo"
set rs1=conn.execute(sql1)
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="Micss.css" rel="stylesheet" type="text/css">
</head>
<body background="Images/fondo_Menu.gif" id="fondo" leftmargin="0">
<p>
<table width="10" border="0" cellspacing="0" style="width:150px;">
<%while not rs1.eof%>
<tr>
<td><img src="<%=rs1("imagen")%>"></td>
</tr>
<%sql2="select * from modasg,modulos where
modasg.cod="&session("codigo")&" and modulos.cod=modasg.codmodulo and
modulos.padre="&rs1("padre")&" order by codmodulo"
set rs2=conn.execute(sql2)
while not rs2.eof%>
<tr><td onMouseOver="this.style.color='#ff9900';"
onMouseOut="this.style.color='#000000';" style="cursor:hand"><div
align="left"><strong>
<font face="MS Sans Serif" size="1"><a
href="<%response.Write(rs2("modulo")+".asp")%>" target="mainFrame">
<%response.Write(""+rs2("modulo")+"")%>
</a></font></strong></div></tr></td>
<%
rs2.movenext
wend
rs1.movenext
wend%>
</table>
<p><br>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
</body>
</html>
can u help me with this?