Article View: borland.public.jbuilder.java.swing
Article #10070Using JEditorPane to Display a Local HTML file
From: Arun Horne
Date: Sun, 14 Nov 1999 00:00
Date: Sun, 14 Nov 1999 00:00
14 lines
1552 bytes
1552 bytes
Hi
I need to use the Java Swing JEditorPane to display an HTML file that is
stored in the ./help/helpFile.htm direcotry. Ie. in a subdirectory below
where my source code is held. I have done the following:
JEditorPane.setEditable(false);
JEditorPane.setPage("help/helpFile.htm");
However I get MalformedURLExceptions from this. Should I specifiy a
protocol? If so how?
Thanks in advance
Arun Horne (arun@aznet.freeserve.co.uk)
Technical Details
Message-ID:
<80q9dc$pno$1@news7.svr.pol.co.uk>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,905daaa275364cdd,start X-Google-Attributes: gid111d45,public X-Google-Thread: f5d71,905daaa275364cdd,start X-Google-Attributes: gidf5d71,public X-Google-Thread: 113ae9,905daaa275364cdd,start X-Google-Attributes: gid113ae9,public X-Google-Thread: 10fd6d,905daaa275364cdd,start X-Google-Attributes: gid10fd6d,public X-Google-Thread: 10a146,905daaa275364cdd,start X-Google-Attributes: gid10a146,public From: "Arun Horne" <cs98abh@cs98abh.fsnet.co.uk> Subject: Using JEditorPane to Display a Local HTML file Date: 1999/11/14 Message-ID: <80q9dc$pno$1@news7.svr.pol.co.uk> X-Deja-AN: 549073105 X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211 X-Complaints-To: abuse@theplanet.net X-Trace: news7.svr.pol.co.uk 942713068 26360 62.137.49.87 (16 Nov 1999 00:44:28 GMT) Organization: Customer of Planet Online X-MSMail-Priority: Normal NNTP-Posting-Date: 16 Nov 1999 00:44:28 GMT Newsgroups: borland.public.jbuilder.java.swing,comp.lang.java,comp.lang.java.gui,comp.lang.java.help,comp.lang.java.programmer