wood burning stoves*
The moose likes Applets and the fly likes Applets and beans Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Applets
Bookmark "Applets and beans" Watch "Applets and beans" New topic

Applets and beans

Vladimir Ergovic
Ranch Hand

Joined: Apr 22, 2001
Posts: 63
Well, situation is like this:
I'm using JSP combined with beans (I fill the beans with user informations and now I have to read all the beans and to put it in applet for processing. So my question is: How can I read and write to the beans from the applets?
Here is some JSP code and how could I do it via applets?
I want to read from get methods and to write to some other bean via set.
String strServiceGroup = null;
Iterator itr = null;
int tmpServiceGroupID= -1,brojac=0;
int popust = 0;

if (myServices != null)
itr = myServices.iterator();

while ((itr != null) && (itr.hasNext())) {
Service tmpService = (Service)itr.next();

if (tmpService.getType() == Service.SERVICE_TYPE_UNIT)
strServiceGroup = "UNIT SERVICES";
else if (tmpService.getType() == Service.SERVICE_TYPE_STOREY)
strServiceGroup = "STOREY SERVICES";
else if (tmpService.getType() == Service.SERVICE_TYPE_FACILITY)
strServiceGroup= "FACILITY SERVICES";


if (tmpServiceGroupID != tmpService.getType()) {
tmpServiceGroupID = tmpService.getType();
<tr bgcolor="#FBF0B5" align="left">
<td colspan="8">
<font face="Verdana" size="2"><b>  <%= strServiceGroup %></b></font>
<td colspan="8"></td>
<td width="20">
if (tmpService.isBasicService()) {
<input type="radio" value="<%= tmpService.getServiceID() %>" name="serviceID" id = "bnt<%=brojac%>" onClick = "toggle ( this,<%=brojac%>);" unchecked> 
<%} else { %>
<input type="checkbox" value="<%= tmpService.getServiceID() %>" name="serviceID" id = "bnt<%=brojac%>" onClick = "toggle (this,<%=brojac%>);" > 


Vladimir Ergovic
It is sorta covered in the JavaRanch Style Guide.
subject: Applets and beans
Similar Threads
view record from database using click event in jsp
How to retrive data two times from database in sinble jsp page.
problem in using Ajax calls
When Validation Error I Lose My Bean Value-Struts 2
How to store answer available in option form in database table?