fercasa8322 de Junio del 2004
Preguntaporfavor soy algo nuevo en asp, segun yo esto esta hecho correctamente pero si aguien em encuentra algun error le agradeceria que me lo dijera, la aplicacion completa consta de 3 archivos, uno sube un archivo el otro sobre escribe el archivo, y por ultimo esta esta pagina que deberia de encargarse de actualizar la base de datos, el error debe de ser aqui porque funciona perfectamente pero no hace modificaciones a la base de datos
<% 'Response.Expires = 0
Server.ScriptTimeOut = 350000
On Error Resume Next
set o = Server.CreateObject("SuperQ.SQuery")
StrCnx1 = "DRIVER=SQL Server;DSN=reporte;SERVER=" & Session("BDPagosWeb") & ";UID= por seguridad no puse el user ;PWD= por seguridad no puse el pass ;APP=;WSID=" & Session("BDPagosWeb") & ";DATABASE=PagosWeb"
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set objTxt = objFSO.OpenTextFile("\asfsmysw2k01Inetpubwwwrootfaconlineihdblacklist.rpt")
consecutivo = 1
errcuenta = 0
%>
<html>
<BODY bgcolor="silver" style="font: 8pt Arial">
<font style="font-size: 12pt"><b>ALTA DE CUENTAS KENAN EN EL BLACKLIST DE EBILLING</b></font><p>
<a href='javascript: history.back();'>Regresar</a><p>
<%
while ((not(objTxt.AtEndOfStream)) and errcuenta = 0)
cuenta = objTxt.ReadLine
if (len(cuenta) > 8) then
response.write consecutivo & ".- " & cuenta & " : <b><font color='red'>NO SE PUDO DAR DE ALTA FORMATO INCORRECTO</font></b> <br>"
consecutivo = consecutivo + 1
else
Set OraDynaset= o.Execute("select * from blacklist where ctaknn = '" & cuenta & "'")
if OraDynaset = true then
response.write consecutivo & ".- " & cuenta & " : <b>YA EXISTE EN BLACKLIST</b> <br>"
else
if OraDynaset.EOF then
if trim(cuenta) <> "" then
response.write consecutivo & ".- " & cuenta & " : <font color='yellow'><b>ALTA</b></font> <br>"
Set sqlseg= o.Execute2("insert into blacklist values('" & cuenta & "',0,'Cuenta bloqueada en intranet')")
end if
end if
end if
if trim(cuenta) <> "" then
consecutivo = consecutivo + 1
end if
end if
WEnd
if errcuenta = 1 then
response.write "<p><B>EL ARCHIVO 'datos.rpt' NO TIENE EL FORMATO ADECUADO PARA BLOQUEAR LAS CUENTAS... FAVOR DE REVISARLO</B><p>"
end if
response.write " <p>Terminado.....<a href='javascript: history.back();'>Regresar</a><br>"
%>
</BODY>
</HTML>
<% 'Response.Expires = 0
Server.ScriptTimeOut = 350000
On Error Resume Next
set o = Server.CreateObject("SuperQ.SQuery")
StrCnx1 = "DRIVER=SQL Server;DSN=reporte;SERVER=" & Session("BDPagosWeb") & ";UID= por seguridad no puse el user ;PWD= por seguridad no puse el pass ;APP=;WSID=" & Session("BDPagosWeb") & ";DATABASE=PagosWeb"
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set objTxt = objFSO.OpenTextFile("\asfsmysw2k01Inetpubwwwrootfaconlineihdblacklist.rpt")
consecutivo = 1
errcuenta = 0
%>
<html>
<BODY bgcolor="silver" style="font: 8pt Arial">
<font style="font-size: 12pt"><b>ALTA DE CUENTAS KENAN EN EL BLACKLIST DE EBILLING</b></font><p>
<a href='javascript: history.back();'>Regresar</a><p>
<%
while ((not(objTxt.AtEndOfStream)) and errcuenta = 0)
cuenta = objTxt.ReadLine
if (len(cuenta) > 8) then
response.write consecutivo & ".- " & cuenta & " : <b><font color='red'>NO SE PUDO DAR DE ALTA FORMATO INCORRECTO</font></b> <br>"
consecutivo = consecutivo + 1
else
Set OraDynaset= o.Execute("select * from blacklist where ctaknn = '" & cuenta & "'")
if OraDynaset = true then
response.write consecutivo & ".- " & cuenta & " : <b>YA EXISTE EN BLACKLIST</b> <br>"
else
if OraDynaset.EOF then
if trim(cuenta) <> "" then
response.write consecutivo & ".- " & cuenta & " : <font color='yellow'><b>ALTA</b></font> <br>"
Set sqlseg= o.Execute2("insert into blacklist values('" & cuenta & "',0,'Cuenta bloqueada en intranet')")
end if
end if
end if
if trim(cuenta) <> "" then
consecutivo = consecutivo + 1
end if
end if
WEnd
if errcuenta = 1 then
response.write "<p><B>EL ARCHIVO 'datos.rpt' NO TIENE EL FORMATO ADECUADO PARA BLOQUEAR LAS CUENTAS... FAVOR DE REVISARLO</B><p>"
end if
response.write " <p>Terminado.....<a href='javascript: history.back();'>Regresar</a><br>"
%>
</BODY>
</HTML>
