Java Programming - A few problems using beans.....
Where to start...
Well, I have got a servlet that creates a new instance of a bean ('generalBean'), then the 'generalBean' runs a query within the DB it connects to. Then 'while(resultSet.next)' it creates an instance of another bean called 'detailedBean' and sets all the variables it has ('v1', 'v2', 'v3').
Now I want the 'generalBean' to return control back to the origional servlet. I know I need a 'return()' command in, but im not really sure what I am supposed to be returning. And it gives an error when I just type 'return()'
End of problem 1
Now once that is done, I need to be able to have the origional servlet (that control has just been passed back to) to check if the 'generalBean' has found any results (and therefore created some instances of 'detailedBean').
If it has, then go to a jsp page, where (somehow) the jsp page will 'include' something, that will walk through each 'detailedBean' and retrieve all the results.
End.
I have been struggling with this for hours now and haven't got a clue where to go on this one. Im not an expert at this yet, so please exlain anything in as much detail as possible.
Thanx
CKS

