jsp - Java error: Only a type can be imported. XYZ resolves to a package -


I get an error: "Only one type of import can be done. XYZ fixes packages."

Someone has interpreted this reason, but I am not sure what to do to fix this. FYI: I am using Eclipse. I added the code that imports below Java.util. * Import works fine.

  & lt;% @ page import = "java.util. *"% <%> & Lt;% @ Page Import = "org.eresearch.knowledgeportal.model.Category"%> & Lt;% @ Page Import = "org.eresearch.knowledgeportal.dao.CategoryDao"%> & Lt;% Range CatDao = New Group (); ArrayList & LT; Category & gt; CatList = catDao.selectCategory (); //%> Edit: The actual error is given below:  
  org.apache.jasper.jasperException: unable to compile class for JSP: on line An error occurred: Only one type of import can be imported into 7 generated Java files. Org.eresearch.nonowportportal.model.Category one package  

OK, you are really I do not provide enough details on your webpad in my estimation that you have something with JSP:

  & lt;% @ page import = "java.util. *, XyZ" % & Gt;  

and xyZ can not be found on the classpath (i.e., under WEB-INF / classes , and no JAR In WEB-INF / lib ).

Repeat the following structure in the war that you bring on Tomcat:

  my-webapp | - Meta-INF | `- MANIFEST.MF | - Web-INF | | - square | | | - x | | | `- Y ​​| | | `- Z Class | | `- Second | | `- Packennam | | | `- Other class. Class | | - lib | | | - ajar.jar | | | - Berger. | `- zjar.jar | `- web.xml | - a.jsp | - B.Jsp` - index.jsp  

or the jar which is present under the bundle xyZclass WEB-INF / lib .


Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

php - Multiple Select with Explode: only returns the word "Array" -

php - jQuery AJAX Post not working -