解決javax.servlet.jsp.JspException cannot be resolved to a type
使用eclipse-juno新建的maven專案,使用過程中無任何問題,但是換了eclipse-luna版本後,匯入同樣的maven專案,則報javax.servlet.jsp.JspException cannot be resolved to a type錯誤;這可能是新版本eclipse的bug導致。
在網上找的解決方案是在你的專案中加入jsp-api.jar和servlet-api.jar包,這兩個包來源於tomcat的libs目錄中,但是會出現一個問題,專案打包釋出的時候也會將這兩個jar打包出去,這時候釋出到tomcat中後tomcat可能啟動失敗,同時你的jar包可能和tomcat中的jar版本不一致等情況。
解決方式:右鍵你的專案--properties選擇Targeted Runtimes,選擇你的執行環境,我選擇Apache Tomcat v7.0,Apply--OK。
相關文章
- xxx cannot be resolved to a type
- The type XXX cannot be resolved.It is indirectly referenced from required .classUI
- Java問題解決:The project cannot be built until build path errors are resolvedJavaProjectUIError
- eclipse中:The type java.lang.object cannot be resolved錯誤(jdk配置錯誤)EclipseJavaObjectJDK
- 解決 TypeError: Type aliases cannot be used with isinstance(). 辦法Error
- cannot convert (type interface {}) to type int: need type assertion
- The type List is not generic; it cannot …
- Cannot infer type arguments for PageImpl
- 解決java.lang.IllegalArgumentException: 'Content-Type' cannot contain wildcard type '*'異常(真實有效)...JavaExceptionAI
- Golang Cannot use ss(type AAA) as type AAA in map indexGolangIndex
- Cannot set property ‘type‘ of null(vue)NullVue
- 解決 Cannot find OpenSSL's
- POST http://xxx net::ERR_NAME_NOT_RESOLVED 解決HTTP
- MySQL could not be resolved: Temporary failure in name resolution報錯解決方法MySqlAI
- 關於Chrome報錯 ERR_NAME_NOT_RESOLVED 解決辦法Chrome
- 解決“su: cannot open session: Permission denied”Session
- cannot allocate new log 的解決方法
- 解決cannot find module providing package或cannot find main modulePackageAI
- Ubuntu Cannot allocate memory 錯誤解決方案Ubuntu
- Jquery DataTables解決 Cannot reinitialise DataTable 問題jQuery
- ImportError: cannot import name ‘imresize‘解決辦法ImportError
- Access restriction: The type 'Resource' is not API 解決辦法RESTAPI
- 解決Cannot find module '@angular/compiler-cli'AngularCompile
- Cannot get a connection, pool exhausted解決辦法
- Cannot find SS.INI file for user *** 解決方法
- TypeError: Descriptors cannot not be created directly問題的解決Error
- PySimpleGUI 引入後VsCode出現問題提示 “could not be resolved” 解決方案GUIVSCode
- MYSQL中 TYPE=MyISAM 錯誤的解決方法MySql
- `QtValidLicenseForCoreModule' does not name a type 錯誤的解決QTREM
- “ORA-28007: the password cannot be reused”解決
- Cannot connect on socket(25)_NetBackup 問題解決
- Material type ROH cannot be used with item category L (plant T001)Go
- 解決 ImportError: cannot import name 'imread' from 'scipy.misc'ImportError
- 解決String cannot be cast to java.util.List報錯ASTJava
- su cannot set user id Resource temporarily unavailable故障解決AI
- 專案問題總結3:MyEclipse匯入專案報錯-"The import javax.servlet cannot be resolved"EclipseImportJavaServlet
- java.lang.IllegalArgumentException: Cannot convert value of type [$Proxy7 implemJavaException
- Only a type can be imported. classname resolves to a package的解決ImportPackage