When i submit the form i have to get the form object in the controller to set the target for that jsp in the controller. I could set the target in jsp but i want to set the target in controller to open the targetted jsp in new window.
I suppose you are not using HTMLB? Otherwise the <form>-Tags would be generated automatically and always point to the controller class that called "this.setJspName(...)". So, for HTMLB, you would use thie method.
Otherwise, I think the best way would be use a bean for transferring the data from the controller to the JSP. Set the target value in the bean in your controller and read it out in the JSP.
Please provide some some details about your problem.
Some example code (what have you done so far, what would you like to do) for betting understanding