Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

displaying html in JTextPane of JDK 1.1.8  RSS feed

 
yashendra chandrakar
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i need to display html content in JTextPane of JDK1.1.8.for that i coded as follows:
....
....
String text="<html><body>‘ Hi,Manjit’</body></html>";
JTextPane tp = new JTextPane();
tp.setContentType("text/html");
tp.setText(text);
....
but its not converting the special character as expected.
same code fragment is working for JDK1.4.
Any clue.
Thanks
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!