Ver Mensaje Individual
  #4 (permalink)  
Antiguo 25/02/2009, 11:53
Avatar de superscully
superscully
 
Fecha de Ingreso: febrero-2009
Mensajes: 56
Antigüedad: 16 años, 2 meses
Puntos: 0
Respuesta: Como Exportar a un Excel?????

gracias... pero es posible que la consulta sea transferida al excel... mostrando los datos en las columnas....

se genera la consulta y la muetra en esta tabla...

<table border="0">
<tr>
<td><b><font face="Tahoma" size="2" color="#000000">Folio</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">NControl</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">Of. Ref.</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">Fecha</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">Remitente</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">Origen</font></b></td>
<td><b><font face="Tahoma" size="2" color="#000000">Destino</font></b></td>
<td><font face="Tahoma">&nbsp;</font></td>
</tr>

<tr>
<td> <font face="Tahoma">
<%fecha1=date
fecha2=rs_consulta("fechadeldocumento")
prioridad=ucase(rs_consulta("prioridad"))
diferencia=datediff("d",fecha2,fecha1)
response.write priodidad
if prioridad="0" or prioridad="1" then
'si ya han pasado 7 dias
if diferencia>=7 then
if rs_consulta("respuesta")="_" or isnull(rs_consulta("respuesta")) then%>
<img src="img/carta.gif" border="0" width="45" height="20" alt="Urge tu respuesta">Urge
respuesta
<% end if
end if
end if
if prioridad="2" or prioridad="3" then
if diferencia>=1 then
if rs_consulta("respuesta")="_" or isnull(rs_consulta("respuesta")) then%>
<img src="img/carta.gif" border="0" width="45" height="20" alt="">Urge
respuesta
<% end if
end if
end if
%>
</font>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> ><font face="Tahoma" size="2"
<%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <a href="uploadframeset.asp?nf=<%=rs_consulta("folio" )%>">
<%=rs_consulta("folio")%> </a></font> </td>
<td <%
if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%>
><font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <%=rs_consulta("NumerodeControl")%> </font> </td>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> ><font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <%=rs_consulta("OficiodeReferencia")%></font> </td>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> ><font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <%=day(rs_consulta("fechadeldocumento"))&"/"&month(rs_consulta("fechadeldocumento"))&"/"&year(rs_consulta("fechadeldocumento"))%></font> </td>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> > <font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>><%=rs_consulta("remitente")%></font> </td>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> > <font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <%=rs_consulta("propietario")%></font> </td>
<td <%if rs_consulta("prioridad")="0" then
response.write ("bgcolor='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="1" then
response.write ("bgcolor='#66CC99'")
end if%>
<%if rs_consulta("prioridad")="2" then
response.write ("bgcolor='#FF9900'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("bgcolor='#FF0000'")
end if%> > <font face="Tahoma" size="2" <%if rs_consulta("prioridad")="2" then
response.write ("color='#FFFFFF'")
end if%>
<%if rs_consulta("prioridad")="3" then
response.write ("color='#FFFFFF'")
end if%>> <%=rs_consulta("destinatario")%></font> </td>
<td> <font face="Tahoma">
<%if rs_consulta("revisado")="1" then %>
<img src="img/ok1.jpg" border="0" width="20" height="17" alt="">
<%end if%>
<%if rs_consulta("enviado")="1" then %>
<img src="img/ok2.jpg" border="0" width="20" height="17" alt="">
<%end if%>
<%if rs_consulta("tipo_de_respuesta")="PRELIMINAR" then %>
<img src="img/respok1.jpg" border="0" width="20" height="17" alt="">
<%end if%>
<%if rs_consulta("tipo_de_respuesta")="FINAL" then %>
<img src="img/respok2.jpg" border="0" width="20" height="17" alt="">
<%end if%>
</font></td>
</tr>
<%
rs_consulta.movenext
LOOP
rs_consulta.close
%>
</table>