
Clauido José
Membros-
Total de itens
457 -
Registro em
-
Última visita
Tudo que Clauido José postou
-
resolvi
-
sDatBaix = rsAcrecimo("DatBaixa") if sDatBaix = "" then sDatBa = "01/01/1900" response.Write("deu" & sDatBa & "<BR>") Response.End() elseif sDatBaix <> "" then response.Write("deu 3" & sDatBa & "<BR>") Response.End() end if alguém pode me ajudar a dizer porque mesmo com a data em branco ele não entra na sDatBaix = "011\1900"
-
Ola pessoal estou com um problema quero colocar um checkbox numa pagina e quando abrir o banco ele verifica se o campo Ativo for = S ele deixa o checkbox checado se não ele não deixa estou fazendo assim mas não ta dando certo <%if rsUsuario("Ativo")="S" then teste="checked" end if%> <td width="12%" class="SubTitulo"><input type="checkbox" name="chkAtivo" value="A" <%=teste%> >
-
Ola pessoal estou quebrando a cabeça para resolver um probleminha numa pagina asp que tenho bom eu não sei se é aqui ou la paginha sobre asp que eu posto este tópico.Se não for me descupem. Bom é seguinte tenho uma pagina asp onte tenho um jumpmenu bom quero que ele recupere o valores do jumpmenu se que ele volte para o inicio da pagina bom criei uma função que puchei na net em ajax mas não to conseguinte quando eu chamo em outra pagina ela recupera as informações mas se eu chamo na mesma pagina não recupera gostaria de uma ajuda ok vou postar o codigo: function trazdadosMotivos() { var arr = new String(frmBaixaOs.seMotivos.value); arr = arr.split('|'); frmBaixaOs.hiMotivos.value = arr[0]; var comboMotivos = createXMLHTTP(); comboMotivos.open("post", "BaixaOs.asp", true); comboMotivos.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); comboMotivos.send("idMotivos=" + frmBaixaOs.hiMotivos.value); } <input type="hidden" name="hiMotivos" value="<%=sMotivos%>" /> <select name="seMotivo" class="campo" id="seMotivos" onchange="trazdadosMotivos();"> <option value="1">Selecione</option> <% strSql = "Select * from tabMotivos" rsMotivos.Open strSql,Conexao,3,3 while Not rsMotivos.Eof %> <option value="idMotivo=<%=rsMotivos("idMotivos")%>"<%if cint(Request.QueryString("idMovito")) = rsMotivos("idMotivos") then%> selected="selected"<%end if%>><%=rsMotivos("DescricaoMotivo")%></option> <% rsMotivos.MoveNext wEnd %> </select> alguém pode me ajudar?
-
Ai vai o codigo mais tenho uma duvida ainda vou mostrar o codigo no final eu coloco ele ok? <html> <link href="css/estilos.css" rel="stylesheet" type="text/css"> <script type="text/JavaScript"> function trazdados() { var combouf = createXMLHTTP(); combouf.open("post", "objEmpresa.asp", true); combouf.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); combouf.onreadystatechange=function() { if (combouf.readyState==4) {// abaixo o texto do gerado no arquivo executa.asp e colocado no div document.all.divcombouf.innerHTML = combouf.responseText; } } } function valida() { if(document.frmGeral.seEmpresa.selectedIndex==0) { alert("Selecione uma empresa"); document.frm.seEmpresa.focus(); return false; } if(document.frmGeral.seTecnicos.selectedIndex==0) { alert("Selecione um tecnico"); document.frm.seTecnicos.focus(); return false; } } function AbrirJanela(janela,Pos1,Pos2,Pos3,Pos4) { window.open(janela,"SESSAO","left="+Pos1+",top="+Pos2+",width="+Pos3+",height="+Pos4) } function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } function processa(iQtdeVetor){ if (consiste_controles(iQtdeVetor)){ document.frm.submit(); } } function consiste_controles(iQtdeVetor){ var bmarcado = false; //Controles NÃO É ARRAY deve ser tratado sem o indíce if (document.frm.chkItem.length == undefined){ if (!document.frm.chkItem.checked){ alert('Selecione pelo menos um item!'); document.frm.chkItem.focus(); return false; } }else{ for (var i=0;i<iQtdeVetor;i++){ if (document.frm.chkItem[ i ].checked){ bmarcado = true; } } //Controles É ARRAY deve ser tratado com o indíce if (!bmarcado){ alert('Selecione pelo menos um item!'); document.frm.chkItem[ i ].focus(); return false; } } return true; } function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } function marca_desmarca(opcao,iQtdeVetor){ //Controles NÃO É ARRAY deve ser tratado sem o indíce if (document.frm.chkItem.length == undefined){ document.frm.chkItem.checked = opcao; }else{ for (var i=0;i<iQtdeVetor;i++){ //Controles É ARRAY deve ser tratado com o indíce document.frm.chkItem[ i ].checked = opcao; } } } </script> <script language="javascript" src="jsp/ajax.js"></script> </head> <body> <!--#include file="strCon.asp"--> <% dim Conexao, strSql, strData, strVetor call abreConexao() if Request.QueryString("atc") = "New" then strNoOs = Request.QueryString("NoOs") stridTecnico = Request.QueryString("idTecnico") data = date dia = datepart ("d", data) mes = datepart ("m", data) ano = datepart ("yyyy", data) strdata = (mes&"/"&dia&"/"&ano) vItensMarcado = split(Request.Form("chkItem"),",") if not IsArray(vItensMarcado) then vItensMarcado = array(vItensMarcado) end if for i = 0 to ubound(vItensMarcado) strSql = "Select * from tabDTH where DatCompromisso = #" & strData & "# " strSql = strSql & " and NoOs = " & vItensMarcado(i) & " order by idEmpresa" set rsRota = Conexao.Execute(StrSql) if not rsRota.Eof then strSql = "Update tabDth Set " strSql = StrSql & "idEmpresa=" & Request.QueryString("Empresa")& "," strsql = strSql & "idTecnico=" & Request.QueryString("idTecnicos") strSql = strSql & " where idDth=" & rsRota("idDth") 'response.Write(strSql) 'response.End() Conexao.Execute(StrSql) end if next end if data = date dia = datepart ("d", data) mes = datepart ("m", data) ano = datepart ("yyyy", data) strdata = (mes&"/"&dia&"/"&ano) campo = "tabDth.NoOs,tabDth.DatCompromisso,tabDth.Periodo,tabDth.QtdPontos,tabDth.Status,tabCidades.Cidade" campo = campo & ",tabCliente.Cep,tabCliente.Bairro,tabCliente.TipoResidencia,tabDth.IdServico,tabTipoOs.Descricao" campo = campo & ",tabDTh.idEmpresa,tabDth.idTecnico" strSql = "SELECT " & campo strSql = strSql & " FROM tabTipoOs INNER JOIN (tabEstados INNER JOIN ((tabCidades INNER JOIN tabCliente ON " strSql = strSql & "tabCidades.idCidade = tabCliente.IdCidade) INNER JOIN tabDth ON " strSql = strSql & "tabCliente.idCliente = tabDth.idCliente) ON (tabEstados.idEstado = tabCliente.IdEstado) " strSql = strSql & "AND (tabEstados.idEstado = tabCidades.idEstado)) ON tabTipoOs.idTipoOs = tabDth.idTipoOs " strSql = strSql & "WHERE (((tabDth.DatCompromisso)=#" & strData & "#))" if rsRota.state = 1 then rsRota.Close rsRota.Open strSql, Conexao, 3, 3 status = "Rota Geral " rs = rsRota.RecordCount %> <form action="atribuirotaGeral.asp?atc=New&Empresa=<%=Request.QueryString("Empresa")%>&idTecnicos=<%=Request.QueryString("idTecnicos")%>" method="post" name="frm" id="frm" onSubmit="valida();" > <table width="700" border="0" align="center" cellpadding="2" cellspacing="2" class="Tabela"> <tr> <td colspan="6"><span class="SubTitulo">Ola<%=Session("Usuario")%> você está em <strong>Intranet DTH 25</strong> <strong>» Atribuição » <%=status%></strong></span></td> </tr> <tr> <td colspan="6"> </td> </tr> <tr> <td colspan="6"><table width="100%" border="0" cellspacing="2" cellpadding="2"> <tr> <td width="50%"><table width="100%" border="0" cellspacing="2" cellpadding="2"> <tr> <td width="24%" class="SubTitulo"> </td> <td width="39%" class="SubTitulo"><label id="Nome">Informe a Empresa:</label></td> <td width="37%" class="SubTitulo"> <select name="seEmpresa" onChange="MM_jumpMenu('this',this,0)"> <option value="atribuirotageral.asp?idEmpresa=0">Selecione</option> <% strSql = "Select * from tabEmpresa" set rsEmpresa = Conexao.Execute(strSql) if not rsEmpresa.Eof then while not rsEmpresa.Eof %> <option value="atribuirotageral.asp?idEmpresa=<%=rsEmpresa("idEmpresa")%>&Empresa=<%=rsEmpresa("Empresa")%>"<%if cint(Request.QueryString("idEmpresa")) = rsEmpresa("idEmpresa") then%>selected<%end if%>><%=rsEmpresa("Empresa")%></option> <% rsEmpresa.MoveNext wEnd end if %> </select> </td> </tr> </table></td> <td width="50%"><table width="100%" border="0" cellpadding="2" cellspacing="2"> <tr> <td colspan="2" class="SubTitulo"><label id="Nome">Informe um tecnico:</label></td> <td width="64%" class="SubTitulo"> <select name="seTecnicos" onChange="MM_jumpMenu('this',this,0)"> <option value="atribuirotageral.asp">Selecione</option> <% strSql = "Select * from tabTecnicos" set rsTecnicos = Conexao.Execute(strSql) if not rsTecnicos.Eof then while not rsTecnicos.Eof %> <option value="atribuirotageral.asp?Opt=VoltaT&idTecnicos=<%=rsTecnicos("idTecnico")%>&idEmpresa=<%=Request.QueryString("idEmpresa")%>&Empresa=<%=Request.QueryString("Empresa")%>"<%if cint(Request.QueryString("idTecnicos")) = rsTecnicos("idTecnico") then%>selected<%end if%>><%=rsTecnicos("Tecnico")%></option> <% rsTecnicos.MoveNext wEnd end if %> </select> </td> </tr> </table></td> </tr> </table></td> </tr> <tr> <td width="10" align="right"> </td> <td width="203"> </td> <td width="102"><input type="button" name="Submit" value="Enviar" onClick="java script: processa(<%=rs%>);"></td> <td width="103"><input name="subLimpar" type="reset" id="subLimpar" value="Limpar" /></td> <td> </td> <td width="126"> </td> </tr> <tr> <td height="10" colspan="6" class="Texto"> </td> </tr> <tr> <td colspan="6" class="Texto"> </td> </tr> <tr> <td colspan="6"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" class="Tabela"> <%Bg="#FFFFFF"%> <tr bgcolor="<%=Bg%>"> <td width="9%" align="center" class="SubTitulo">No. Os</td> <td width="7%" align="center" class="SubTitulo">Serviço</td> <td width="14%" align="center" class="SubTitulo">Tipo Os </td> <td width="9%" align="center" class="SubTitulo">Periodo</td> <td width="6%" align="center" class="SubTitulo">Status</td> <td width="9%" align="center" class="SubTitulo">CEP</td> <td width="10%" align="center" class="SubTitulo">Cidade</td> <td width="6%" align="center" bgcolor="<%=Bg%>" class="SubTitulo">Bairro</td> <td width="10%" align="center" class="SubTitulo">Residencia </td> <td width="20%" align="center" class="SubTitulo"> </td> </tr> <tr> <td colspan="10" valign="top"><div><table width="100%" border="0" align="left" cellpadding="1" cellspacing="1" class="Tabela1" style="margin-left:0"> <% if not rsRota.Eof then dim i i =0 vVetor = 0 while Not rsRota.EOF if Bg="#FFFFFF" then Bg="#5082B4" else Bg="#FFFFFF" end if %> <tr bgcolor="<%=Bg%>"> <td width="10%" class="SubTitulo"><%=rsRota("NoOs")%></td> <td width="7%" align="center" class="SubTitulo"><%=rsRota("idServico")%></td> <td width="16%" align="center" class="SubTitulo"><%=left(rsRota("Descricao"),20)%></td> <td width="11%" align="center" class="SubTitulo"><%=rsRota("Periodo")%></td> <td width="6%" align="center" class="SubTitulo"><%=rsRota("Status")%></td> <td width="11%" align="center" class="SubTitulo"><%=rsRota("Cep")%></td> <td width="10%" align="center" class="SubTitulo"><%=left(rsRota("Cidade"),10)%></td> <td width="10%" align="center" class="SubTitulo"><%=left(rsRota("Bairro"),10)%></td> <td width="10%" align="center" class="SubTitulo"><%=left(rsRota("TipoResidencia"),10)%></td> <td width="20%" class="SubTitulo"><input name="chkItem" type="checkbox" class="campo" id="chkItem" value="<%=rsRota("NoOs")%>" /> <%if rsRota("idEmpresa") <> 0 then%> <%=rsRota("idEmpresa")%> <%end if%> - <%if rsRota("idEmpresa")<>0 then%> <%=rsRota("idTecnico")%> <%end if%></td> </tr> <% rsRota.Movenext wEnd end if %> </table></div></td> </tr> </table></td> </tr> <tr> <td colspan="4"> </td> <td class="SubTitulo"><input name="optMarca" type="radio" value="radiobutton" onClick="java script: marca_desmarca(true,<%=rs%>);" > Marcar Todas</td> <td span class="SubTitulo"><input name="optDemarca" type="radio" value="radiobutton" onClick="java script: marca_desmarca(false,<%=rs%>);"> Desmarcar Todas</td> </tr> <tr> <td colspan="4"> </td> <td width="120" class="SubTitulo"> </td> <td width="126" span class="SubTitulo"> </td> </tr> </table> </form> </body> </html> Minha duvida é a seguinte quando eu por exemplo clicar no checkbox e depois selecionar um tencio ou uma empresa ele descheca o item que eu selecionei como faço para resolver isso?
-
Era isso mesmo criei um loop ficou mais facil
-
Ola pessoa tenho que criar um vetor com a quantidades de registros de um recordset mas tem que ficar da seguinte maneira. se rs.RecordCount = 10 o vetor vai ficar da seguinte maneira vVetor = "1, 2, 3, 4, 5, 6, 7, 8, 9, 10"
-
resolvi
-
bom andei pesquisando no foum e descobri a função slipt pra quebrar os valores enviados pelo checkbox bom estou fazendo da seguinte maneira mas ta dando um erro. vItensMarcado = split(Request.Form("cheNoOs"),",") Response.Write(vItensMarcado) Response.End() O erro que aparece na tela é seguinte Objeto Response, ASP 0106 (0x80020005) Um tipo de dados não identificado foi encontrado.
-
E se eu fazer da seguinte maneria como fica <script language="javascript"> function valor(){ for (i = 0; i < document.formulario.nivel.length; i++) { if (document.formulario.nivel[i].checked == true) { var id = i; var valor = document.formulario.nivel[i].value; break; } } if (valor=='') { alert("não selecionado"); } else { alert('A opção selecionada foi a de número ' + id); alert('O valor é ' + valor); } } </script> <form name="formulario" onsubmit="valor();"> nivel: <input type="radio" name="nivel" id="nivela" value="Administrador">Administrador <input type="radio" name="nivel" id="nivels" value="Supervisor">Supervisor <input type="radio" name="nivel" id="nivelg" value="Gerente">Gerente <input type="radio" name="nivel" id="nivelo" value="Operador">Operador<br /> <br /> <label> <input type="submit" name="Submit" value="ENVIAR" /> </label> <br /> </form> como eu valido se ele foi selecionado ou não
-
Resolvi em parte mas meu problema é séguitente vou mostrar como eu fiz depois eu mostro o resolutado ok.
-
bom é o seguinte eu tenho uma pagina feita em asp e nela eu abro uma tela com um loop que me traz dados desta tabela bom eu coloquei um checkbox para cada registro que o registro cria vou ilustrar <form action="atribuirotaGeral.asp?atc=New" method="post" name="frmGeral" id="frmGeral" onSubmit="return valida();"> <table width="700" height="450" border="0" align="center" cellpadding="0" cellspacing="0" class="Tabela"> <Tr> <td>Dados da tabela</td> </tr> <%do while not rs.eof%> <tr> <td><%=rs("NOme")%></td> </tr> <tr> <td><input type="checkBox" name="seNome" valeu="<%=rs("idCliente")%>></td> </tr> <%rs.Movenext%> <%loop%> <tr> <td width="12%"> </td> <td width="28%"><input name="subEnviar" type="submit" id="subEnviar" value="Enviar"></td> <td colspan="3"><input name="subLimpar" type="reset" id="subLimpar" value="Limpar"></td> </tr> </table> bom quando eu clico em enviar ele tem que verificar se o checkbox criado pelo loop estão selecionado mas as vezes não vao ser todos que estarão selecionado.Se por exemplo tiver nenhum selecionado ele da a mensagem se caso tiver um selecionado e os outros não ele não da a mensagem.
-
Tudo bem entendi agora tenho outra duvida sobre isto esta dentro do loop, ele cria um checkbox para cada registro como faço o javascript entender que se por exemplo eu clicar em um registtro não tem validar já que os outros não estõa checados.
-
Olha da uma olhada neste exemplo eu criei este menu com banco de dados quem sabe ajuda. A diferença é que só tem categoria e subcategoia <!--#include file ="strCon.asp"--> <% call abre_conexao strSql = "SELECT IDCategoria,Descricao FROM tbCategoria" 'Response.Write(strsql) 'response.End() set rsCategoria = Conexao.Execute(strSql) %> <script> function mostraEsconde(id) { document.getElementById('sub_menu_1').style.display='none'; document.getElementById('sub_menu_2').style.display='none'; document.getElementById('sub_menu_3').style.display='none'; if (id.style.display=='none') { id.style.display=''; } else { id.style.display='none' } } function menu_over(id) { document.getElementById("table"+id).bgColor = "#ebebeb" document.getElementById("table"+id).style.cursor="hand" } function menu_out(id) { document.getElementById("table"+id).bgColor = "#f9f9f9" } </script> <link href="estilos/estilos.css" rel="stylesheet" type="text/css"> <body leftmargin="0" topmargin="0"><table width="100%" cellspacing="0" cellpadding="0" border="0" class="texto"> <tr> <td width="203" height="1" bgcolor="#FFFFFF"></td> </tr> <%While Not RsCategoria.EOF i=i+1%> <tr> <td bgcolor="#EFEFEF" height="20" class="tituloMenu"><img src="images/dot.gif" width="9"><img src="images/img_plus.gif" width="9" height="9" style="cursor:hand" onClick="mostraEsconde('<%=i%>');"><img src="images/dot.gif" width="5"><a href="mostraCategoria.asp?idCategoria=<%=RsCategoria("idCategoria")%>"><span class="tituloMenu"><b><%=RsCategoria("Descricao")%></b></span></a></td> </tr> <% strsql = "SELECT IDSUBCATEGORIA,IDCATEGORIA,DESCRICAO FROM TBSUBCATEGORIA WHERE IDCATEGORIA = " & CINT(rscategoria("idCategoria")) Set RsSubCategoria= Conexao.Execute(strsql) If not RsSubCategoria.EOF Then%> <%if RsCategoria("idCategoria")=cInt(Request.QueryString("idCategoria")) Then%> <tr id="<%=i%>" style="display:none"> <%Else%> <tr id="<%=i%>" style="display:none"> <%End If%> <td><table width="100%" border="0" cellpadding="0" cellspacing="0" class="texto"> <%While Not RsSubCategoria.EOF x=x+1%> <tr> <td width="6%" align="right"> </td> <td width="3%" align="right"><img src="images/imgPontCurvaMenu.gif" width="11" height="11"></td> <td width="91%"><a href="mostraSubCategoria.asp?idCategoria=<%=RsSubCategoria("idCategoria")%>&idSubCategoria=<%=RsSubCategoria("idSubCategoria")%>"><%=RsSubCategoria("Descricao")%></a></td> </tr> <%RsSubCategoria.MoveNext Wend RsSubCategoria.Close Set RsSubCategoria=Nothing%> </table> </td> </tr> <%End If%> <tr> <td height="1" bgcolor="#ffffff"></td> </tr> <tr> <td height="1" bgcolor="#b8b8b8"></td> </tr> <%RsCategoria.MoveNext Wend%> </table> <%RsCategoria.Close Set RsCategoria=Nothing %>
-
eu tenho que atualizar o id do tecnico e id da empresa tava fazendo com o select mas tava dando muito trabalho então optei pelo checkbox é uma boa porque to fazendo duas telas numa só.
-
è o seguinte eu quero atualizar somente o que ta marcado.
-
Bom pessoal estou com uma duvida de novo bom criei uma tela onde eu coloquei dentro de um loop dados de uma tabela que vou selecionar para futura atualização bom para checala eu coloque um checkbox com value do id da tabela. Bom o que eu quero quando o usuario clicar em vario dados deste loop ele me atualize a tabela. Bom vou colocar o codigo para você verem como funcional.
-
cara não to entendendo nada eu quero validar um checkebox quando no submit do form criei uma função chamada valida() e nela verifico se o check esta checado ou não informando ao usuario
-
Ola pessoal estou com uma duvida como eu valido se o checkbox esta selecionado ou não pelo javascript
-
sim obrigado.
-
Ola pessoal estou com uma duvida até quantos inner join eu posso abrir num select?
-
bom eu fiz da seguinte maneira tinha que abrir a mesma tabela para que ficasse da seguinte maneira. Tecnico Servico Total AB AC BC CA NF RP Hora Inicio CLAUDIO 10 10 10 0 0 0 0 0 Assim até terminasse os tecnicos da empresa bom fiz da seguinte maneira, sendo que AB, AC, BC, CA, NF, RP e um campo da tabela chamanda status seria o status do servico. não sei se existe uma maneira mais facil de fazer isso se tiver me ajudem? Ai vai a querys campos = "tabDth.DatCompromisso, tabDth.idTecnico, tabTecnicos.Tecnico, Count(tabDth.idTecnico) AS Total, Count(tabDth.NoOs) AS ContarDeNoOs," campos = campos & "tabDth.Status, tabDth.idServico, tabDth.idEmpresa, tabDth.HoraInicio" strSql = "Select " & campos & " FROM tabDth INNER JOIN tabTecnicos ON tabDth.idTecnico = tabTecnicos.idTecnico" strSql = strSql & " GROUP BY tabDth.DatCompromisso, tabDth.idTecnico, tabTecnicos.Tecnico, tabDth.Status, tabDth.idServico, tabDth.idEmpresa," strSql = StrSql & " tabDth.HoraInicio HAVING tabDth.DatCompromisso=#" & strData & "#" strSql = strSql & " AND tabDth.idEmpresa=" & Request.QueryString("idEmpresa") rsRota.Open strsql,Conexao, 3,3 'separa Rotas Geral Com Status AB strSql = "SELECT datCompromisso,Count(Status) AS ContarAB FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='AB'" rsRota1.Open strSql, Conexao, 3, 3 'separa a rota geral por status = AC strSql = "SELECT datCompromisso,Count(Status) AS ContarAc FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='Ac'" rsRota2.Open strSql, Conexao, 3, 3 'separa a rota geral por status = BC strSql = "SELECT datCompromisso,Count(Status) AS ContarBC FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='BC'" rsRota3.Open strSql, Conexao, 3, 3 'separa a rota geral por status = CA strSql = "SELECT datCompromisso,Count(Status) AS ContarCA FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='CA'" rsRota4.Open strSql, Conexao, 3, 3 'separa a rota geral por status = NF strSql = "SELECT datCompromisso,Count(Status) AS ContarNF FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='NF'" rsRota5.Open strSql, Conexao, 3, 3 'separa a rota geral por status = RP strSql = "SELECT datCompromisso,Count(Status) AS ContarRP FROM tabDth GROUP BY DatCompromisso,Status" strSql = strSql & " HAVING DatCompromisso=#" & strData & "# AND Status='RP'" rsRota6.Open strSql, Conexao, 3, 3 status = "Geral » Tecnico"
-
Oi tudo bem desculpe mas não estou conseguindo com esse codigo estou fazendo da seguiinte maneira de uma olhada por favor estou quebrando a cabeça. <% while Not rsRota.EOF if Bg="#FFFFFF" then Bg="#5082B4" else Bg="#FFFFFF" end if %> <tr bgcolor="<%=Bg%>"> <!-- <td width="10%" height="10" class="SubTitulo"><%=rsRota("NoOs")%></td> <td width="6%" align="center" class="SubTitulo"><%=rsRota("idServico")%></td> <td width="14%" align="center" class="SubTitulo"><%=rsRota("Descricao")%></td> <td width="10%" align="center" class="SubTitulo"><%=rsRota("Periodo")%></td> <td width="7%" align="center" class="SubTitulo"><%=rsRota("Status")%></td> <td width="10%" align="center" class="SubTitulo"><%=rsRota("Cep")%></td> <td width="11%" align="center" class="SubTitulo"><%=left(rsRota("Cidade"),10)%></td> <td width="11%" align="center" class="SubTitulo"><%=left(rsRota("Bairro"),10)%></td> <td width="12%" align="center" class="SubTitulo"><%=left(rsRota("TipoResidencia"),10)%></td> --> <td width="12%" align="center" class="SubTitulo"> <select name="Empresa&<%=i%>" class="campo" style="width:200" onChange="MM_jumpMenu('this',this,0)"> <% strSql = "Select * from tabEmpresa " set rsEmpresa = Conexao.Execute(strSql) %> <option>Selecione</option> <% while not rsEmpresa.Eof %> <option value="atribuirotageral.asp?idEmpresa=<%=rsEmpresa("idEmpresa")%>&Empresa=<%=rsEmpresa("Empresa")%>"<%if Request.Form("seEmpresa")&i = rsEmpresa("Empresa") or Request.QueryString("idEmpresa") = rsEmpresa("idEmpresa") then%> selected="selected"<%end if%>><%=rsEmpresa("Empresa")%></option> <% rsEmpresa.movenext wEnd %> </select> </td> <td class="SubTitulo"><%response.Write("empresa" & Request.Form("seEmpresa")& i)%></td> </tr> <% i = i + 1 rsRota.Movenext wEnd end if %> O que ta acontecendo é o seguinte quando eu seleciono um select ele na ta deixando selecionado fica como se não tivesse selecionado qual o erro. pessoal cera que alguém pode me ajudar com este codigo obriado
-
Opa desculpe consegui resolver apenas tirando o count da emrpesa e colocando somente no count da os. Em questao do meu tópico do select sera que da pra ajudar?
-
Entendi obrigado é isso mesmo estava fazendo uns testes no access ele se eu fazer campo por campo ele traz certinho o total do registro mas se eu colocar mas de um campo ele traz todos os registro individualmente porque?