Preface
After analyzing the login module of the Weibo case, I tried to follow up the myweibo project on the welcome page last time. HoweverCodeThere are still some import classes that are always unable to be found. I looked at the location, which is part of the API package provided by sina. Due to the large number of files, I tried to delete some irrelevant files at the beginning, errors are reduced. Finally, the classes in the external jar files are referenced, so I cannot find out how to use these jar files for a long time.
Solve the problem
The root cause of the problem is to import an external jarProgramCall (Figure 4 shows the error location of the corresponding code). If you are familiar with Eclipse, you should be able to solve the problem quickly. It is the first time you have encountered the problem of introducing an external JAR file. Here we will write down the solution steps, and some people may encounter this problem like me.
1. Copy the JAR file to the lib directory;
2. Find the referenced libraries directory in the project. I use the latest eclipse indigo J2EE version. This directory is not available by default. This problem is mainly caused by the fact that eclipse hides the empty referenced libraries directory by default, we need to add it on our own. Click the inverted triangle in the upper right corner = "filters =" to deselect the check box for empty library containers and empty packages. For details, see:
3. Now you can go to the referenced libraries directory, right-click build Path =, and then click Configure build path ..., Click Add jars in the pop-up menu to add the jar files in the lib directory one by one.
Now, the error disappears.
The problem of referencing external jar is solved, but it is impossible to log on when deployed to the simulator, and the real location of the logon progress bar is always in progress. Therefore, the revolution has not yet succeeded. comrades still need to work hard, when the test is OK, complete the code analysis ...... To be continued .....