HI, I have a bean with some private variables and get and set methods. I'm setting their values from a html page, using its request parameters to match the properties in the bean, via a jsp page. When I use the set property tag in the jsp page as: <jsp:setProperty name="mybean" property="*" /> all the properties in the bean are not being set. Instead, if I explicitly use <jsp:setProperty name="mybean" property="bean_prop1" /> for all the properties I have in the bean, their values are being set from the request parameters. Am I doing something wrong here, or does specifying "*" in setproperty tag need something more ? Any response will be very helpful. Thanks.
Hmm... Then it may be an implementation thing because in IBM's Visual Age for Java/WebSphere environment I have coded info beans with all private fields, but with the corresponding public accessor and mutator methods, and it works as expected with the "*"
Tony Alicea Senior Java Web Application Developer, SCPJ2, SCWCD
The JSP spec says they should be valid bean properties -- ie, have setters. Not a word about public variables. If the implementation doesn't work with these, it is faulty. I've encountered peculiarities before, though, if the case of the parameters didn't exactly match that of the properties. - Peter
HI BHIDU(FRIEND), I HAVE BEANS IN A FOLDER OF TOMCAT/WEBAPPS. WHEN I TRY TO ACCESS BEAN IN JSP I GET ERROR THAT BEAN NOT FOUND. DO I NEED TO SET CLASS PATH OF BEAN?? PLZ LEMME KNOW EXACT STEPS OF USING BEAN: WHERE TO STORE THEN WHAT?? THEN JSP:USEBEAN ETC.