Trying to parse a HTML page using JSoup parser in Android?
<p>So far I've tried this example which I just took from this site but it is not working in my case and I don't know why?! Is there anyone who can tell me how can I solve this problem, here is the code: this code shows me NullExceptionPointer</p>

<p>And i tried to print the doc.select() it shows me error :s null excetptionpointer.</p>

<pre><code> URL url = null;
try {
    url = new URL("http://www.nseindia.com/content/equities/niftysparks.htm");
} catch (MalformedURLException e) {
    // TODO Auto-generated catch block
    e.printStackTrace();
}
Document doc = null;
try {
    doc = Jsoup.parse(url, 3000);
} catch (IOException e) {
    // TODO Auto-generated catch block
    e.printStackTrace();
}

Element table = doc.select("table[class=niftyd]").first();

Iterator&lt;Element&gt; ite = table.select("td[width=65]").iterator();

ite.next(); // first one is image, skip it

System.out.println("Value 1: " + ite.next().text());
System.out.println("Value 2: " + ite.next().text());
System.out.println("Value 3: " + ite.next().text());
System.out.println("Value 4: " + ite.next().text());
</code></pre>

<p>Any help I would really appreciate it, I'm fighting for the whole day and I cant solve it! :s</p>
