Estou com um probleminha..
bom tenho um banco de dados com 3 campos
eve_codigo
eve_nome
eve_permissao_tutor
esses campos estao na tabela "Evento".
bom eu preciso listar os dados da tabela, todos junto com isso tenho que colocar um checkbox na pagina com o value = 1,
eu consigo listar normalmente mas tenho que postar o o form com javascript quando dou um submit da um erro de sintaxe ..
alguem pode dar uma mao??
ERRO: Obejeto esperado Linha 78
pagina que contem o form e lista os dados
<!--#include virtual="/includes/lms_header.asp"-->
<style type="text/css">
<!--
.style1 {color: #FF0000}
-->
</style>
<form name="cursos" method="post" action="recebe.asp" >
<input type="hidden" name="usu_codigo" id="usu_codigo" value="<%=usu_codigo%>" >
<table WIDTH=400 BORDER=0 CELLPADDING=0 CELLSPACING=0 ID="Table2">
<TR>
<TD width="20" height="300" bgcolor="#EFEFEF"><IMG SRC="../agrupamento/images/layout/spacer.gif" WIDTH=1 HEIGHT=1 ALT=""></TD>
<TD COLSPAN=2 valign="top" align="center">
<table width="100%" height="73" border="0" cellpadding="0" cellspacing="0" ID="Table3">
<tr>
<td valign="top"> </td>
<td width="99" rowspan="3" valign="top"><IMG SRC="/images/layout/img_inclusao.gif" WIDTH=99 HEIGHT=96 ALT=""></td>
</tr>
<tr>
<td valign="top"> <span style="font-weight: bold">Seleção de Cursos para o Ciclo</span></td>
</tr>
<tr>
<td valign="top" style="padding-left:10px;padding-right:10px;margin-top=-50px;">
<table border="0" cellpadding="0" cellspacing="0" ID="Table4" >
<tr>
<td align="center">
<table width="65" border="0" cellpadding="0" cellspacing="0" class="input_botao" ID="Table1">
<tr onClick="java script:Verifica();" onMouseOver="this.className='input_botao_sel';" onMouseOut="this.className='input_botao';">
<td width="25" height="25" align="center"><img src="/images/icones/ico_16x16_atualizar.gif" width="16" height="16"></td>
<td>Gravar</td>
</tr>
</table> </td>
<td width="1"> </td>
<td>
<table width="65" border="0" cellspacing="0" cellpadding="0" class="input_botao" ID="Table5">
<tr onClick="java script:FAgrupamento.reset();" onMouseOver="this.className='input_botao_sel';" onMouseOut="this.className='input_botao';">
<td width="25" height="25" align="center"><img src="/images/icones/ico_16x16_limpar.gif" width="16" height="16"></td>
<td>Limpar</td>
</tr>
</table> </td>
<td width="1"> </td>
<td>
<table width="65" border="0" cellspacing="0" cellpadding="0" class="input_botao" ID="Table8">
<tr onClick="window.close();" onMouseOver="this.className='input_botao_sel';" onMouseOut="this.className='input_botao';">
<td width="25" height="25" align="center"><img src="/images/icones/ico_16x16_fechar.gif" width="16" height="16"></td>
<td>Fechar</td>
</tr>
</table> </td>
</tr>
</table> </td>
</tr>
</table>
<table width='100%' border='1' cellspacing='0' cellpadding='2' bordercolor="#EEEEEE" style="border: 2px solid #DFDFDF" ID="Table9">
<tr class="tabela_dados_titulo">
<td><strong>Associação de Tutor / Cursos </strong><br>
<span class="style1">Máximo de 5 cursos por Tutor </span></td>
</tr>
<tr>
<td height="25" valign="top"><table width="98%" border="0" cellspacing="0" id="Table10">
<tr class="tabela_dados_titulo">
<td align="left" valign="top">
<%
sql =" select eve_codigo , eve_nome , eve_permissao_tutor from evento ORDER BY eve_nome"
rs_cursos=func_Open(sql,1)
if isarray(rs_cursos)=TRUE then
num_reg=ubound(rs_cursos,2)
For i=0 to num_reg
eve_codigo=rs_cursos(0,i)
eve_nome=rs_cursos(1,i)
eve_permissao_tutor=rs_cursos(2,i)
sql=" select eve_codigo from evento where eve_codigo= " & eve_codigo & " and eve_nome=" & eve_nome
rs_t=func_Open(sql,1)
aux=""
if isarray(rs_t)=true then
aux=" checked "
end if
negado=0
if (eve_codigo=True or eve_codigo = 1 ) then
negado=1
end if
%>
<% if negado=0 then %>
<table width="369" border="0">
<tr>
<td width="17" bgcolor="#FFFFFF" ><% RESPONSE.Write "<input "&aux&" type='checkbox' name='part' id='ch_cur' value='1'>" %>
<% RESPONSE.Write "<input "&aux&" type='hidden' name='cod' id='ch_cur' value='"&eve_codigo&"'>" %></td>
<td width="335" bgcolor="#FFFFFF"><% response.Write rs_cursos(1,I) %></td>
</tr>
</table>
<% end if
Next
else
response.Write (" Não Existem Cursos Disponíveis ")
end if %>
</td>
</tr>
<tr>
<td>
<div align="center">
<table width="70" border="0" cellpadding="0" cellspacing="0" class="input_botao" ID="Table1">
<tr onClick="java script:Verifica();" onMouseOver="this.className='input_botao_sel';" onMouseOut="this.className='input_botao';">
<td width="25" height="25" align="center"><img src="/images/icones/ico_16x16_atualizar.gif" width="16" height="16"></td>
<td align="left">Gravar</td>
</tr>
</table>
</div></td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table>
</form>
</body>
<script language="JavaScript1.2" type="text/javascript">
function Verifica()
{
if (document.cursos.ch_cur.checked==true)
{
document.cursos.action="recebe.asp";
document.cursos.submit();
}
}
else
{
selecionado = "";
cont = 0;
cont_sel=0;
}}}
if(document.cursos.ch_cur.length!=undefined)
{
while (cont < document.cursos.ch_cur.length)
{
if (document.cursos.ch_cur[cont].checked)
{
if (selecionado == ''){
selecionado+= document.cursos.ch_cur[cont].value;
}else{
selecionado+= ',' + document.cursos.ch_cur[cont].value;
}
cont_sel=cont_sel+1;
}
cont++;
}
}
else
{
if(document.cursos.ch_cur.checked)
{
if (selecionado == ''){
selecionado+= document.cursos.ch_cur.value;
}else{
selecionado+= ',' + document.cursos.ch_cur.value;
}
}
}
if(cont_sel > 5 )
{
alert("Possui mais de 5 cursos escolhido! ");
return false;
}
document.cursos.submit();
}
}
function desativar()
{
i=0;
while(i<document.cursos.ch_cur.length){
if (document.cursos.ch_inativo.checked==true)
{
document.cursos.ch_cur[i].disabled=true;
}
else
{
document.cursos.ch_cur[i].disabled=false;
}
i = i+1;
}
}
</script>
<!-- FIM CONTEÚDO -->
<!--#include virtual="/includes/lms_bot.asp"-->Agradeço desde ja!!
Abraços a todos.










