1.cannot be resolvedä»ä¹åå
cannot be resolvedä»ä¹åå
xxx cannot be resolved to a type é误解å³æ¹æ³ï¼cannotresolvedxxx cannot be resolved to a type é误解å³æ¹æ³ï¼cannotresolved
xxx cannot be resolved to a type
å¼è¨ï¼
eclipseæ°å¯¼å ¥ç项ç®ç»å¸¸å¯ä»¥çå°âXX cannot be resolved to a typeâçæ¥éä¿¡æ¯ãæ¬æå°å以ç®åæ»ç»ã
æ£æï¼
ï¼1ï¼jdkä¸å¹é ï¼æä¸åå¨ï¼
项ç®æå®çjdk为âjdk1.6.0_âï¼èå½åeclipse使ç¨çæ¯âjdk1.6.0_âãéè¦å¨BuildPath | Librariesï¼ä¸åç®åè°æ´ã
ï¼2ï¼jarå 缺失æå²çª
å½æ¾ä¸å°âXXâæå¨çjarå æ¶ï¼ä¼æ¥è¿ä¸ªéã解å³åªéè¦æ¾å°ï¼ctrl+ç¹å»ï¼å¯è½è½çå°jarå å称ï¼å¯¹åºjarå å¯¼å ¥é¡¹ç®å³å¯ã
å¦å¤ï¼åºç°ç¸åçXXæ¶ä¹ä¼æ¥æ¤éãå¯è½éè¦è°å ã解å ãéå ã
ï¼3ï¼eclipseæ¥æ¾é¡¹ç®ç±»åçç¥æè´
eclipseä¸ï¼ä¸è¿°ä¸¤æ¡é½å¯¹æ¯è¿äºï¼æ²¡æä»»ä½é®é¢ï¼å¯ååè¿æ¥è¿éãè¿æ¶ï¼éè¦æä½ä¸ä¸ Project | Clean... ï¼é®é¢å³å¯è§£å³ãåå æ¯ï¼æºå¶æè´ãå 为æäºç¹æ®åå ï¼eclipse没è½èªå¨ç¼è¯æºä»£ç å°build/classesï¼æå ¶ä»classesç®å½ï¼ï¼å¯¼è´ç±»åæ¥æ¾ä¸å°ã
以ä¸è¿äºæ¯æ¯è¾å¸¸è§çé误ï¼æè¿ééå°çé误æ¯æ件ç¼ç 导è´çï¼
é误类似ä¸å¾ï¼è¿éåªæªåä¸é¨åï¼
解å³æ¹æ³ï¼
å¨åçé误ç项ç®ä¸åå»é¼ æ å³é®ãProperties
左侧éä¸âResourceâï¼å³ä¾§Text file encodingéæ©âOtherï¼UTF-8âï¼ç¹å»âApplyâæé®ã
String cannot be resolved to a type è¿ä¸ªé®é¢æ解å³ï¼ä¸ä¸æ¯æºä»£ç ä¸çé误
cannot be resolved to a type è¿ç§é®é¢ä¸è¬æ¯ç¸å ³jarå æªå¼å ¥å¯¼è´æ²¡æ³è¯å«è¿ä¸ªç±»åï¼ä½ä½ è¿ä¸ªæ¯Stringç±»åæ æ³è¯å«ï¼åºè¯¥æ¯ä½ çeclipse没ææ¾å°JDK,源码源码后门检测éæ°å¨é¦é项ä¸è®¾ç½®ä¸ä¸åéæ°ç¼è¯åºè¯¥å°±å¯ä»¥äºã
cannot be resolved to a typeåºè¿ä¸ªé误æ示ï¼ä¸å ±æå¤å°ç§å¯å¯ä»¥ï¼
cannot be resolved to a type
çåé¢æä¹æ¯æ æ³è¯å«çç±»åï¼ä¹å°±æ¯è¯´ä½ ç代ç ä¸æå¯è½æ
1.æªå¯¼å ¥çå .
2.åéçClass Name.
3.æªå建å´è¢«ä½¿ç¨çåé.