2

I thought I had this perfectly working but apparently not. I left my project for a vacation, then when I came back and tried to open it, I am getting:

The import org.jsoup cannot be resolved

in all the files that have that import.

If I delete that import and try to automatically resolve Document, it inserts import org.w3c.dom.Document; instead.

What happened to the system and how can I fix this?

Environment: Eclipse 3.6.2 + SDK 3.2 (API13) + jsoup-1.6.1.jar (under Windows XP)

Regex Rookie
  • 10,432
  • 15
  • 54
  • 88
  • 1
    Make sure jsoup-1.6.1.jar is in your classpath. – yorkw Jan 12 '12 at 02:10
  • @yorkw Thanks +1. I double-checked `Project > Properties > Java Build Path > Libraries`. jsoup-1.6.1.jar is there. I tried removing it, then adding it again but that didn't help. Any ideas? – Regex Rookie Jan 12 '12 at 02:13

5 Answers5

3

In order to get rss links from html source code i used Jsoup java library. Download and add the jar file to your project Java Build Path library.

You can download the jar file by going to http://jsoup.org/download

Once downloaded Right Click on project -> properties -> Select Java Build Path (on left side) -> Select third tab Libraries (on right side) -> Add External Jar -> Browse to downloaded jsoup .jar file.

after this procedure if problem is not solved then right click on Jsoup.jar -> add to build path.

Chetan Gaikwad
  • 1,268
  • 1
  • 13
  • 26
1

Problem solved (sort of):

It turns out that I tried to start Eclipse under an XP account that's different than the Administrator.

Now I have to find out how to make it work under the other account as well.

Regex Rookie
  • 10,432
  • 15
  • 54
  • 88
  • 1
    Bad practice, but I always start Eclipse as Administrator. There are a couple of things that don't really work otherwise (maybe there would be solutions... but complicated ;). – Dominik Bucher Jan 12 '12 at 02:30
  • @Dom Now I am facing a [debug certificate expired](http://stackoverflow.com/questions/8501237/existed-recipe-to-fix-eclipse-debug-certification-bug-does-not-work) problem... I of course tried the measures described [here](http://stackoverflow.com/questions/2194808/debug-certificate-expired-error-in-eclipse-android-plugins) but they didn't help. This makes me miss Microsoft's Visual C++ IDE so much... :-( – Regex Rookie Jan 12 '12 at 03:00
0

Try add 1.6.1.jar to libs directory in the root folder.

0

You can download the jar jsoup Once downloaded Right Click on project -> [![properties -> Select Java Build Path (on left side) -> Select third tab Libraries (on right side) -> Add External Jar -> Browse to downloaded jsoup .jar fileafter this procedure if problem is not solved then right click on Jsoup.jar -> add to build path][1]][1]

https://i.stack.imgur.com/nCr2d.jpg

sirmagid
  • 1,090
  • 1
  • 16
  • 23
0

Check Project Properties -> Java Build Path -> Libraries. Make sure jsoup-1.6.1.jar is there.

Edit: Ups, just saw your comment. Project -> Clean... is usually good, too. Or restarting eclipse.

Dominik Bucher
  • 1,509
  • 13
  • 16