
Hello...this is Prashant khandekar..i am very much new to JSP and tomcat. So i just wanted to ask you i m working on very basic project in which there will be 2 text boxes "start" and "end" this text boxes will contain 2 different numbers in which "start will hav 1" and "end will hav 2" and i want following is to b printed; 1 12 123 1234 12345... till number mentioned in the textbox "end"
thanx in advance...

1)pattern.jsp:
<html> <form method="post" action="getvalue.jsp"> <pre> Enter start: <input type="text" name="num1"><br> Enter end : <input type="text" name="num2"><br> <input type="submit" value="Submit"> </pre> </form> </html>
2)getvalue.jsp:
<%
String number1=request.getParameter("num1");
String number2=request.getParameter("num2");
int n1=Integer.parseInt(number1);
int n2=Integer.parseInt(number2);
for(int i=n1;i<=n2;i++){
for(int j=n1;j<i+1;j++){
out.print(j);
}
out.println("<br>");
}
%>

thnx a lott ...but i juss wanna ask dat on click event of pattern.jsp will the getvalue.jsp file will get opened and will print the patterns?
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.