<%@LANGUAGE="VBSCRIPT"%> <% if request.form("nuevo") = "Nuevo" then response.redirect "nuevo_personal.asp" end if %> Mantenimiento de datos <% Dim cnn,rst set cnn = Server.CreateObject("ADODB.Connection") set rst = Server.CreateObject("ADODB.Recordset") cnn.open "DSN=Directorio;UserId=web;Password=odaliska$$$;UID=web" if session("usuario_dir")="none" OR session("usuario_dir")="" then session("usuario_dir")="none" response.write ("Usted no esta registrado, por favor regístrese") response.end end if dim sqltext dim idi idi = request.querystring("id") sqltext = "Select * from institucional Where [id] = cast(('"&idi&"') as int) ORDER BY SIGLA" rst.open sqltext,cnn,3,3,1 if rst.eof and rst.bof then 'response.write("Escoga un rubro para empezar"+id_rub) end if %> <%''GRABAR LOS DATOS rst("rubro")=request.form("rubr") rst("entidad")=request.form("enti") rst("tipo")=request.form("tipo") rst("sigla")=request.form("sigl") rst("significa")=request.form("sign") rst("ape_resp1")=request.form("ape1") rst("cumpdia")=request.form("dia") rst("cumpmes")=request.form("mes") rst("nom_resp1")=request.form("nom1") rst("ape_resp2")=request.form("ape2") rst("nom_resp2")=request.form("nom2") rst("cargo")=request.form("car1") rst("cargo2")=request.form("car2") rst("direccion1")=request.form("dir1") rst("direccion2")=request.form("dir2") rst("postal")=request.form("post") rst("ciudad")=request.form("ciud") rst("pais")=request.form("pais") rst("tele1")=request.form("tel1") rst("tele2")=request.form("tel2") rst("tele3")=request.form("tel3") rst("fax")=request.form("fax") rst("celular1")=request.form("cel1") rst("celular2")=request.form("cel2") rst("email1")=request.form("ema1") rst("email2")=request.form("ema2") rst("pagweb")=request.form("pagw") rst("secretaria")=request.form("secr") rst("administra")=request.form("admi") rst("jefe1")=request.form("jef1") rst("jefe2")=request.form("jef2") rst("jefe3")=request.form("jef3") if request.form("even") = "checked" then rst("eventos")=true else rst("eventos")=false end if if request.form("navi") = "checked" then rst("navidad")=true else rst("navidad")=false end if if request.form("otro") = "checked" then rst("otros")=true else rst("otros")=false end if rst.update() %>


<% Dim letra,b,buscar letra = request.form("eliminar") b = Mid(letra, 1, 8) buscar = trim(Mid(letra, 9)) if b="Eliminar" then cnn.execute("delete from institucional Where [id] = cast( ('"&idi&"') as int)") response.write("Se ha elimado el registro seleccionado") response.redirect "buscar_personal.asp?id="&buscar end if %> <% if request.form("grabar")="Grabar" then%>
">
Rubro:
Entidad: Tipo:
Apellidos: " class="cristhian"> Nombre : " class="cristhian"> Cumpleaños:
Cargo: " class="cristhian"> Compañia: " class="cristhian">

Dia: Mes:

Dirección:
Cod. Postal: " size="8" maxlength="200" class="cristhian">
Ciudad: " size="15" maxlength="200" class="cristhian"> País: " size="15" maxlength="200" class="cristhian">  Celular 1:   " size="15" maxlength="200" class="cristhian">
Teléfono 1: " size="15" maxlength="200" class="cristhian"> Teléfono 2: " size="15" maxlength="200" class="cristhian">    
Email 1: " size="20" maxlength="200" class="cristhian"> Email 2: " size="22" maxlength="200" class="cristhian"> Página Web: " size="22" maxlength="200" class="cristhian">
Eventos <%if rst("eventos")=true then%> <%else%> <%end if%> Tarjetas <%if rst("navidad")=true then%> <%else%> <%end if%> Otros: <%if rst("otros")=true then%> <%else%> <%end if%>


<% rst.close set rst = nothing set rst = Server.CreateObject("ADODB.Recordset") sqltext = "Select * from institucional where entidad='Natural' ORDER BY SIGLA" rst.open sqltext,cnn,3,3,1 while not rst("id")=codigo rst.movenext wend if rst.bof then else rst.moveprevious end if if rst.bof then rst.movenext end if %> " class="cristhian">Anterior
<% if not rst.eof then rst.movenext end if if not rst.eof then RST.MOVENEXT end if if rst.eof then rst.moveprevious end if %> " class="cristhian">Siguiente
" class="cristhian">

<%end if%>