--- Geeta Kottapalli <[EMAIL PROTECTED]> wrote:
> Thanks for the quick responses!!
>
> Sorry for the typos in the code.
> I did atually use document.frm.submit();
> and I used the same case for requested parameters.
>
> Srinivas, I tried the way you suggested but did not
> work.
>
> The sample code is as follows.When selection is
> changed in the listbox, appropriate info must be
> displyed
>
> <%@ page language="java"%>
>
> <jsp:useBean id="db" scope="request"
> class="oatsapp.GeneralOats" />
> <jsp:setProperty name="db"  property="*" />
>
> <HTML>
> <HEAD><TITLE>RYGStatus</TITLE>
>
> <Script language="JavaScript">
>
>   function assignID() {
>
>     var id =
> document.frmStatus.lstPrograms.selectedIndex;
>     var prog_ID =
> document.frmStatus.lstPrograms.options[id].value;
>
>     document.frmStatus.method="post";
>       //var
>
path="http://localhost:8080/oatsapp/Status.jsp?progID="
> + prog_ID;
>       document.frmStatus.action='Status.jsp?progID='
> +
> prog_ID;
>       document.frmStatus.submit();
>   }
> </script>
> </HEAD>
>
> <BODY>
> <FORM name="frmStatus" TARGET="Content">
>
> <%! String prog_ID = request.getParameter("progID");
> %>
> <% if !(prog_ID == null) {
        int v_progId = Integer.parseInt(prog_ID);
     }
  %>
> <!-- CALLING THE FUNCTION assignID() on onCHANGE
> event
> -->
>
> <Select name="lstPrograms" onChange="assignID();">
>
> <% String program[][] = db.getProgramsList();
>    for (int i=0; i<program.length; i++ ) { %>
>
>        <option  value="<%=program[i][0]%>"
>          <%=(Integer.parseInt(program[i][0]) ==
> v_progId ? "SELECTED>": ">")%>
>          <%=program[i][1]%>
>        </option>
>  <% } %>
>
> </select>
> </body>
> </html>
>
>
>
> If any one knows the solution please let me know!!
>
> Thanks,
> Geeta
>
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Photos -- now, 100 FREE prints!
> http://photos.yahoo.com
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with
> body: "signoff JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets


__________________________________________________
Do You Yahoo!?
Yahoo! Photos -- now, 100 FREE prints!
http://photos.yahoo.com

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to