• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

How to identify a particular selected record in struts?

Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am working on an application using Struts in which i want to delete and modify the records displayed from the database in a table.
i have done with displaying the records. but i dont get the details about which record is selected for deletion or modification. I want to get all column values for that particular selected row.

I have attached the source code for the jsp page from which i want to navigate to another page with the details of the selected record. please can anyone help me for this issue.

<%@ page import="java.util.*" %>

<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>

<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Search Results</title>
<script language="javascript">
function backtoSearch()

<html:form action="/more" method="post">
<P align="center"> <font size=4> Searching for a particular school.<br> </font> </P>
<table cellspacing =3 cellpadding =6 align ="center" border="1">

<th> School Name  </th>
<th> Location   </th>
<th> District  </th>
<th> </th>
<th> </th>


<logic:iterate id="list" name="results">
<bean:write name="list" property="scName"/>
<input type="hidden" name="name" value="<bean:write name="list" property="scName"/>"/>

<bean:write name="list" property="distName"/>
<input type="hidden" name="location" value="<bean:write name="list" property="distName"/>"/>

<bean:write name="list" property="stateCode"/>
<input type="hidden" name="district" value="<bean:write name="list" property="stateCode"/>"/>

<html:submit property="options" value="Delete"></html:submit>

<html:submit property="options" value="Modify"></html:submit>


<table align="center">
<td> <html:button property="back" onclick="backtoSearch();"> Cancel </html:button> </td> </tr>

You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
    Bookmark Topic Watch Topic
  • New Topic