4
I have two combobox, I need to get the id of one to load the other from the item that was selected in the combobox1,how could I do this through a javascript function.
<select id="cb_catinsumo" class="combo" name="cb_catinsumo" class="combo2">
<option value="">Selecione uma categoria</option>
<%monta combo de categoria de insumos sSQL="SELECT categoria_insumo FROM tb_catinsumo ORDER BY categoria_insumo" oQueryCatInsumo.Open sSQL, oConexao IF NOT oQueryCatInsumo.EOF THEN oQueryCatInsumo.MoveFirst DO until oQueryCatInsumo.EOF%>
<option value="<%=oQueryCatInsumo(" categoria_insumo ").value %>">
<%=oQueryCatInsumo( "categoria_insumo").value %>
</option>
<% oQueryCatInsumo.MoveNext LOOP ELSE %>//sem categorias cadastradas
<option value="">NÃO HÁ CATEGORIAS CADASTRADAS</option>
<% END IF %>
</select>
Can you put your HTML? otherwise we will reply to imagine your code.
– Sergio
@Sergio, my code is the one where you fill the first combo,,
– Everton
Everton, no problem. You can put the code, then select all and do CTR+K, to make a TAB to the whole code.
– Sergio
Got it @Sergio, through this code would have some idea how to help me?
– Everton
Everton, ASP is not my strong suit, but this select is exported correctly, right? and you want to call another select according to its choice. Then you need to use ajax. Give a few minutes that surely someone safer than me in ASP will help more. The important thing is that you explain the question as best you can.
– Sergio
Yes it is exported correctly, ok thanks for helping me up to this point.
– Everton