wood burning stoves 2.0*
The moose likes Struts and the fly likes logic:iterate indexed= Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "logic:iterate indexed="true"" Watch "logic:iterate indexed="true"" New topic
Author

logic:iterate indexed="true"

sanju sreedharan
Ranch Hand

Joined: Nov 25, 2008
Posts: 48
actually i am having a very big problem regarding this...i have three input field place interview,date interview and time of interview...i have a button "add" so that i can send multiple request at a time..
my issue is suppose after adding first detail and press add i am getting the same value again..instead of getting blank...can anyone help me out with an example..i am using struts
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30123
    
150

Sanju,
Welcome to JavaRanch!

Why don't we start with the code you have now? What have you written and what error do you get?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
sanju sreedharan
Ranch Hand

Joined: Nov 25, 2008
Posts: 48
this is my jsp file....and when i run this program all my feilds get hidden and when i remove the present and iterate logic it comes visible...can you help me


<logic resent name="SelectionForm" >
<logic:iterate id="notify_dept_interview_time" name="SelectionForm" property="notify_dept_interview_time" >

<table width="100%" border=0 class="type1" cellspacing="2" cellpadding="5">
<logic:equal name="User" property="notify_dept_interview_time" value="1">
<tr>
<td width="15%" align=right class="type1"><a href="javascript:showMe(document.Selection.place_interview)">Interview Place& Comments</a></td>
<td width="22%" class="type1"> <html:textarea property="place_interview" indexed="true"
<td width="15%" align=right class="type1"> Date/Time : </td>
<td width="22%" class="type1"><html:text property="date_interview" indexed="true" readonly="true" styleClass="input_medium" /><html:img src="../images/cal.gif" onklick="return showCalendar('date_interview','%d/%m/%Y %H:%M', '12', true);" style="cursor:hand;" width="16" height="16"/></td>
<td width="15%" align=right class="type1">Userid </td>
<td width="22%" class="type1"> <html:text property="interview_schedule_userid" indexed="true" readonly="true" styleClass="input_medium"/></td>
</tr>
<tr>
<td colspan=3 align=middle class="type1"><a href="javascript:void()" onklick="javascript:return resumesearch()"> Candidates for Interview</a></td>
</tr>

</logic:equal>
</table>

</logic:iterate>
</logic resent>

my selection form looks like this

public class SelectionDetails {
private String vacancy_refno="";
private String recycle_no="";
private String place_interview="";
private String date_interview="";

public String getVacancy_refno() {
return vacancy_refno;
}
public void setVacancy_refno(String vacancy_refno) {
this.vacancy_refno = vacancy_refno;
}

public String getRecycle_no() {
return recycle_no;
}
public void setRecycle_no(String recycle_no) {
this.recycle_no = recycle_no;
}

public String getPlace_interview() {
return place_interview;
}
public void setPlace_interview(String place_interview) {
this.place_interview = place_interview;
}

public String getDate_interview() {
return date_interview;
}

public void setDate_interview(String date_interview) {
this.date_interview = date_interview;
}
can you help me to solve this
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

I don't see an ActionForm there; are you sure you're iterating over a property that exists in the form? You can also begin to diagnose the problem by putting something in the JSP between the ifPresent and iterate tags to narrow down what the problem might be.

Please use the UBB code tags when posting code, and disable smilies.
sanju sreedharan
Ranch Hand

Joined: Nov 25, 2008
Posts: 48
can you please tell me about UBB code tags?
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

See all thouse UCC code buttons underneath the text box when you reply? And the link "What is UBB Code?"

They might provide clues.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: logic:iterate indexed="true"
 
Similar Threads
jsp exception while using logic:iterate
Newbie in project- need help as to how to proceed with code
dynamically adding
care to be taken for interview in Infosys