Priya Jotwani

Ranch Hand
+ Follow
since Oct 30, 2002
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Priya Jotwani

Hi All,

I am studying for SCJP 1.5 too because I feel thats the best way I could learn about the Java 1.5 features. There is no point giving SCJP 1.4 exam when we already have the upgraded version in the market.

Study 1.5,its fun
Hi,

I have a JSP Page where I have a multiple selection Listbox. When the user submits the page, there should be some values in this listbox. How do I make the validations for the same in validator.xml ?
I have done similar thing for dropdown by the following entry in validator.xml

<field property="reportType" depends="required ">
<arg0 key="prompt.reportType"/>
</field>

How can I achieve the similar thing for Multi Select ListBox ?

TIA,
Priya
19 years ago
Thanks Marc for your reply. It seems to be working now . The problem was that I hadn't specified the input attribute in my Struts-config.xml.

But now I have one more problem . I have 4 JSP Pages and one ActionForm class for all these pages. Now I need to validate the input fields of all the 4 JSPs(i.e all the fields are required). Now , if in my Validator.xml, I specify all the fields , it fires all the validations on the very first page(ie. it cribs abt the fields on page 2,3 and 4 as Required). How can i handle such situation ?

TIA,
Priya
19 years ago
Hi,

I am trying to use Struts validator framework.I have a JSP Page where I have two dropdowns. Both the dropdowns have some default values. When the user clicks on Submit button , he should not be allowed to go to the next page if he has not selected anything from the two dropdowns.
I am doing something like this but am able to proceed without getting an error message on the JSP Page



TIA,
Priya
19 years ago
I have validations in my validator.xml and have corresponding .properties file.
19 years ago
Hi,

I have a JSP Page which has two dropdown fields. If the user selects something from first dropdown and doesn�t selects anything from the second dropdown, it displays me an error message saying �This field is required�. But now I have a scenario wherein, on selecting a particular value from first dropdown should not force the user to select something from the second dropdown (i.e he should be able to proceed even if he doesn�t selects anything from the second dropdown). How can I implement this is Struts ?

TIA,
Priya
19 years ago
Hi Marc,

I had set validate="false" but it doesn't help. I tried removing validate attribute also from the action mapping but to no avail.
What else cud be the reason

Thanks,
Priya
19 years ago
Hi ,

I am facing a problem in my Struts application. When I Submit the page, it gives me an error message as below :

� SRVE0026E: [Servlet Error]-[action]: com.ibm.servlet.engine.webapp.WebAppErrorReport: No input attribute for mapping path /ReportAttribute �

My JSP Code snippet is as below:

<html:form name="ClientReportingForm" type="com.fmr.fiis.ppc.cda.form.ClientReportingForm" method="Post" action="ReportAttribute.do" >

function submit_action() {
document.ClientReportingForm.subAction.value = 'next';
alert("The action is"+document.ClientReportingForm.action);
alert("The subaction is"+document.ClientReportingForm.subAction.value);
document.ClientReportingForm.submit();
}

This is my Struts-config.xml entry.

<action path="/ReportAttribute" type="com.fmr.fiis.ppc.cda.action.ClientReportingAction" name="ClientReportingForm" scope= "request">
<forward name="success" path="/WEB-INF/jsp/cda/SelectFunds.jsp"/>
<forward name="cancel" path="/WEB-INF/jsp/cda/error.jsp"/>
<forward name="error" path="/WEB-INF/jsp/cda/error.jsp"/>
</action>

Any Idea as to why it gives this error. I have tried giving validat=�false� also. If I supply the input attribute in <action mapping>, it always goes to that JSP and not my Resultant Page.

Please let me know as to where I am going wrong.

Thanks,
Priya
19 years ago
Hi Marc,

I saw you other comment too but even that doesn't quit fit into my situation.This is because I override a Base Action class which has its Execute method signature as below :

public String exec(ActionMapping mapping,ActionForm form,HttpServletRequest request,HttpServletResponse response).

Thanks,
Priya
19 years ago
Hi Jeanne,

I am getting the hidden variable value now beacuse I set that in a Javascript Submit of my page. But now in my Action Class, if I access a ActionForm property(which I had selected in JSP page) , it doesn't gives me anything(not even null).

ClientReportingForm myForm = (ClientReportingForm ) form
String strProductLine = myForm.getProductLine();

WHY

Thanks,
Priya
19 years ago
Jeanee, I have checked and its the same.
19 years ago
Hi,

I have a dropdown in my JSP page along with a hidden variable . I select something from the dropdown and Submit the form. In my Action Class, when I try to access the hidden variable value as below :

ClientReportingForm myForm = (ClientReportingForm) form;
strSubAction = myForm.getSubAction();

But this strSubAction is always null. Why is my ActioForm not getting populated when I submit the page.
Please HELP !!

TIA,
Priya
19 years ago
Hi,
i am gettinh the following error msg :

"No input attribute for mapping path /ReportAttribute "

PLease let me know as what cud be the reason.

TIA,
Priya
19 years ago
Hi,

I tried even the <html:text> but Nothing Works
PLEASE HELP

TIA,
Priya
19 years ago
Hi Sheldon,

I tried putting the value in the value attribute of html ption tag . But that doesn't work either. I have imported the strtuts-html.tld with the correct path . Also its has entry in my web.xml.
Can it because I have not put my ActionForm.class file in the classes folder of WEB-INF ??

TIA,
Priya
19 years ago