| | |
beans
Please support our JSP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Mar 2008
Posts: 57
Reputation:
Solved Threads: 0
consider i have this bean
Now I have jsp file..
Now with this code name was fadi, i changed it into lol. Now I want to change it back to the original one. I dont want to do it by calling beanid.setname("fadi"); .. is there any other way?? thank you very much.
JSP Syntax (Toggle Plain Text)
private string name = "fadi"; public String getname() { return (name); } public String setName(String name1) { name = name1; return (name); }
Now I have jsp file..
JSP Syntax (Toggle Plain Text)
<% beanid.setname("lol"); beanid.getname(); %>
Now with this code name was fadi, i changed it into lol. Now I want to change it back to the original one. I dont want to do it by calling beanid.setname("fadi"); .. is there any other way?? thank you very much.
•
•
•
•
I dont want to do it by calling beanid.setname("fadi"); .. is there any other way??
<jsp:setPropery> tag, but may I ask what you are trying to achieve with it ? "Any fool can write code that a computer can understand. Good programmers write code that humans can understand."
"How to ask questions the smart way ?"
"How to ask questions the smart way ?"
•
•
Join Date: Mar 2008
Posts: 57
Reputation:
Solved Threads: 0
yes i can tell you. I have dictionary of words stored as array string ..
"ADD","DELETE" and so on..
I have a form where user enters words he wants to translate
say he adds ADD and his translation insert..
now array[0] is changed to insert ..
but in case he then deletes the the record( record that add = insert in the database), I want the array[0] to be back equal to ADD.
This is assignment I have. I also have to use getname(0) for add buttons..
so in case he changed it to insert, button value is insert...
"ADD","DELETE" and so on..
I have a form where user enters words he wants to translate
say he adds ADD and his translation insert..
now array[0] is changed to insert ..
but in case he then deletes the the record( record that add = insert in the database), I want the array[0] to be back equal to ADD.
This is assignment I have. I also have to use getname(0) for add buttons..
so in case he changed it to insert, button value is insert...
Last edited by hajjo; Aug 29th, 2009 at 2:33 pm.
![]() |
Similar Threads
- jsp&beans (Java)
- On-Site Software Engineer needed ASAP (NJ) -- Java, Java Beans, UNIX (Tech / IT Consultant Job Offers)
- collection of beans (JSP)
- Java Beans (Java)
- jsp using java beans (Community Introductions)
- how to copy a file from one machine to another using beans? (Java)
- beans bound property: getNewValue() doesn't work out. Code attached (Java)
Other Threads in the JSP Forum
- Previous Thread: read value from jsp page to servlet
- Next Thread: reset a bean to null
| Thread Tools | Search this Thread |
apache backbutton combobox connection database development directorystructure dynamicpagetitles eclipse frames glassfish ie8 imagetodatabse imageupload integer internet java javaee javascript jsf jsp jsppagetitles levels mvc2 mvcmodel2 network parameters passing ping printinserverinsteadofclient redirect request.getparameter response servlet servletdopost()readxml sessions software ssl state_saving_method stocks sun tomcat tutorial update video web






