checkbox - JSP - Passing String Array to a constructor -


I have jsp1 where the user checks two of the check boxes, able to successfully read the checkbox value using strings on jsp2 is.

But I need to create a user object with the selected parameter on jsp1, so that I can write it in a text file. This is where I'm blocking a road block when I run the code independently, the Java console is working fine. But the actual code is not. I get an error below

  An error occurred on the line: 29 in the jsp file: /ProcessMyForm.jsp Constructor user (string, string, string, string, string, string [], string ) Is undefined 26: string path = sc.getRealPath ("/ WEB-INF / EmailList.txt"); 27: 28: // Use the normal Java object 29: User user = New user (username, email address, password, comment, email format, server script, business); 30: user.ed (user, path); 31:%> 32:   

The code below is where I am reading the JSP value and trying to create an object

  parameters   

Below is the code for the public class {Private string username; Private string email address; Private string password; Private string comment; Private string email format; Private string server script []; Private string business;

  @SuppressWarnings ("empty-statement") public user () {userName = ""; Password = ""; Email address = ""; Comment = ""; Email format = ""; Business = ""; } Public user (string username, string email address, string password, string comment, string email format, string [] server script, string business) {this.userName = userName; This.emailAddress = emailAddress; This.password = password; This.comment = Comment; This.emailFormat = emailFormat; This.serverScript = serverScript; This.occupation = Business; }   

Would you please help me solve this issue? I need additional information, please let me know

When I stopped and opened Netbeans, It worked. My professor told me that sometimes the updated class is not selected by the server.

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -