Forums Register Login

how to capture dynamically generated value

+Pie Number of slices to send: Send
Hi All,

I have a jsp page which displays a dynamically generated table of values which has two columns of information.

Column1 Column2
100 some info
200 some more info
300 some other info
...

The values 100, 200, 300 are all dynamically generated and can vary each time.

What I want to do is, whenever user clicks on any of these values (i.e. 100 or 200 or 300 etc), I should capture this value and pass it to the next jsp/servlet page for further processing.

Please let me know how I can capture this value whenever user click on any of these values.
[ April 15, 2006: Message edited by: Bear Bibeault ]
+Pie Number of slices to send: Send
Hi Pramod,

You can consider writing your table generation code as follows

<table>
// some logic to decide the number of rows generated
<tr>
<td><a href="yournextservlet?value=<%=value%>"><%=value%></a></td>
<td>Your info</td>
</tr>
</table>

Hope this helps

Vivek
+Pie Number of slices to send: Send
Thanks Vivek Pandey, I am able to do it.
My, my, aren't you a big fella. Here, have a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 680 times.
Similar Threads
ragarding usage of innerhtml
hyperlink-event using a servlet
How to find a value from a graph image in .gif format
JSp-urgent
how to send 100's of textfields data to a servlet?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 04:47:29.