0
I have two select’s Multiple as if they were a From > To, in "From" I have mailing list coming from bank with ASP Classic, I can already pass the emails to the select "To", but I can’t get the emails in the transport function, I would like the help of you if you can use a way to get these values that are in select.
<HTML>
<HEAD>
<TITLE>Mailing</TITLE>
<link rel="stylesheet" href="../../../Estilos/estilos.css" type="text/css">
<script src="../../../JS/functions.js"></script>
<script language="JavaScript">
function Transporte() {
var retEmails;
var objSelecionados = document.frmSelecionaEmail.Selec.value;
alert("Pegou os e-mails");
alert(objSelecionados);
if (objSelecionados != '') {
for (i = 0; i <= objSelecionados.options.length; i++) {
if (objSelecionados.options[i].selected = true) {
retEmails = objSelecionados[i].value;
}
}
} else {
alert("Nenhum e-mail selecionado.");
}
alert(retEmails);
}
</script>
</HEAD>
<BODY topmargin="5" leftmargin="0">
<form name="frmSelecionaEmail" method="post" action="">
<!--CORPO-->
<td width="2%" class="subInfoTit"><input type="submit" name="btOk" value="Ok" class="cmd" onclick="return Transporte();" /></td>
<table width="100%" border="0" cellpadding="2" cellspacing="0" class="tbllogin">
<tr>
<td class="subInfoTit" colspan="2">
<%if Session("SGALinguagem") = "PT" then %>
Lista por E-mail
<%elseif Session("SGALinguagem") = "ES" then %>
Lista por Correo elecrónico
<%elseif Session("SGALinguagem") = "EN" then %>
List by E-mail
<%end if%>
</td>
</tr>
<tr height="21">
<td colspan="7" width="100%">
<table border="0" cellpadding="2" cellspacing="2" width="100%">
<tr>
<td align="center" width="45%"><b>
<%if Session("SGALinguagem") = "PT" then %>
E-mails selecionados
<%elseif Session("SGALinguagem") = "ES" then %>
Correo electrónico no seleccionados
<%elseif Session("SGALinguagem") = "EN" then %>
Unselected E-mails
<%end if%>
</b></td>
<td align="center" width="10%"></td>
<td align="center" width="45%"><b>
<%if Session("SGALinguagem") = "PT" then %>
E-mails não selecionados
<%elseif Session("SGALinguagem") = "ES" then %>
Correo electrónico seleccionados
<%elseif Session("SGALinguagem") = "EN" then %>
Selected E-mails
<%end if%>
</b></td>
</tr>
<tr>
<td align="center" width="45%">
<select name="NSelec" size="8" multiple style="width: 100%;">
<%
SQL="SELECT Email_Endereco, Email_Nome FROM Email"
Call AbreRS(SQL)
While Not Rs.EOF
'v_Id_Email = Rs("Id_Email")
'v_Email_Nome = Rs("Email_Nome")
v_Email_Endereco = Rs("Email_Endereco")
%>
<option value="<%=v_Email_Endereco%>"><%=v_Email_Endereco%></option>
<%
Rs.MoveNext
Wend
Call FechaRS
%>
</select>
</td>
<td align="center" width="10%">
<input type="button" value=">" name="Ins_Item" style="border: 1px solid #636396;color: #636396;width:30px;cursor:hand;" OnClick="MoveDadosLista('Selec', 'NSelec', false);"><br>
<input type="button" value=">>" name="Ins_Todos" style="border: 1px solid #636396;color: #636396;width:30px;cursor:hand;" OnClick="MoveDadosLista('Selec', 'NSelec', true);"><br>
<input type="button" value="<<" name="Ret_Todos" style="border: 1px solid #636396;color: #636396;width:30px;cursor:hand;" OnClick="MoveDadosLista('NSelec', 'Selec', true);"><br>
<input type="button" value="<" name="Ret_Item" style="border: 1px solid #636396;color: #636396;width:30px;cursor:hand;" OnClick="MoveDadosLista('NSelec', 'Selec', false);">
</td>
<td align="center" width="45%">
<select name="Selec" size="8" multiple style="width: 100%;">
</select>
</td>
</tr>
</table>
</td>
</tr>
</table>
</form>
</BODY>
</HTML>
I know the "selects" field is empty at the end, but is there any way to get him to check it out? Because this screen there is a popup that will send the emails to the main screen in a field to my mailing system, thank you.
– Leandro Azevedo