1. 說明
常發生編譯時,出現 Conversion to Dalvik format failed: Unable to execute dex: null 訊息,主要是因為加入 JAR 檔時,以 Add External JARs.... 加入;後來搜尋資料,發現以 Add Library/User Library 比較不會有error訊息。
2. 加入User Library 步驟
1. Right-click the project in Eclipse and select "Build Path -> Add Libraries...".
2. Select User Library from the list and click Next.
3. Click the "User Libraries..." button.
4. Click "New..." in the User Libraries dialog.
5. Give the user library a name and select the System library checkbox and click OK.
6. Highlight the newly added user library in the list and click the "Add JARs..." button and add the desired jar files.
7. Click OK on the User Libraries dialog.
8. Make sure the new user library is checked in the Add Library dialog.
沒有留言:
張貼留言