File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

online help

 
Rasika Chitnis
Ranch Hand
Posts: 131
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having trouble displaying online html help file. I did exactly same as what is given in java tutorial for swing/JEditorPane. Can someone throw some light on what is wrong in following code ??
helpPane = new JEditorPane();
try{
String urlStr = "file:" + System.getProperty("user.dir") + System.getProperty("file.separator") + "index.html";
URL url = new URL(urlStr);
helpPane.setPage(url);
helpPane.setEditable(false);
JScrollPane helpScrollPane = new JScrollPane(helpPane, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
helpScrollPane.setPreferredSize(new Dimension(250, 145));
System.out.println("loading help file : " + urlStr);
}
catch (Exception e){
System.out.println("can not access help file" + e);
}
THANS A LOT !!
 
Farouk Mohamed1
Ranch Hand
Posts: 113
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
There is a problem with using
html tag it will not work properly inside a JEditorPane use
instead.
Any other problem come back to me
Farouk
 
Farouk Mohamed1
Ranch Hand
Posts: 113
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
use tag "

" instead of "
". "
" will not work
Farouk
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic