Load html again...

Hi all,
There are lots of topics in this forum about loading HTML into applet, i tried to find answer from them to solve my problem, but i can't get the expected anwser, can anybody look at my problem, thanks.
I copy the codes from JTree tutorial( http://java.sun.com/docs/books/tutorial/uiswing/components/tree.html ), and try to create a Jar file of it, but the html pages can't be loaded. The codes are:
private class BookInfo {
public String bookName;
public URL bookURL;
public String prefix = "file:"
+ System.getProperty("user.dir")
+ System.getProperty("file.separator");
public BookInfo(String book, String filename) {
bookName = book;
try {
bookURL = new URL(prefix + filename);
} catch (java.net.MalformedURLException exc) {
System.err.println("Attempted to create a BookInfo "
+ "with a bad URL: " + bookURL);
bookURL = null;
private void createNodes(DefaultMutableTreeNode top) {
DefaultMutableTreeNode category = null;
DefaultMutableTreeNode book = null;
book = new DefaultMutableTreeNode(new BookInfo
("Print",
"hf/PrintHelpfile.htm")); //******file can't be loaded
top.add(book);
//Tutorial Continued
I know getClass().getResource("hf/PrintHelpfile.htm") can solve the problem, but i tried several ways to put it into the createNodes method, seems still can't...
Anybody can give me some suggestions, it already take me the whole day...
thanks in advance
dejie

problem sovled

Similar Messages

  • How to load html in loader

    Hi,
    I am loading one swf file in loader. but it was notatall
    loading here. That movie size is more than 1mb. But if i open the
    same file with html script, the move is able to open in the browse.
    So, can i load that html in my loader. Can anybody give sample code
    to load html in loader. Or any other better tycnique.
    my html script:
    <!-- saved from url=(0022)
    http://internet.e-mail -->
    <html xmlns="
    http://www.w3.org/1999/xhtml"
    xml:lang="en" lang="en">
    <head>
    <meta http-equiv="Content-Type" content="text/html;
    charset=iso-8859-1" />
    <title>FFG temp landing pg</title>
    </head>
    <body bgcolor="#ffffff">
    <!--url's used in the movie-->
    <!--text used in the movie-->
    <!-- saved from url=(0013)about:internet -->
    <object
    classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="
    http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0"
    width="875" height="600" id="FFG temp landing pg"
    align="middle">
    <param name="allowScriptAccess" value="sameDomain" />
    <param name="movie" value="rotation.swf" /><param
    name="quality" value="high" /><param name="bgcolor"
    value="#ffffff" /><embed src="rotation.swf" quality="high"
    bgcolor="#ffffff" width="875" height="600" name="FFG temp landing
    pg" align="middle" allowScriptAccess="sameDomain"
    type="application/x-shockwave-flash" pluginspage="
    http://www.macromedia.com/go/getflashplayer"
    />
    </object>
    </body>
    </html>
    Thanks

    Hi,
    I as trying to play swf move only. I am able to play file of
    small size, but this file is too large. I think that might be the
    probelm. But, i am able to play the file from the html code i
    given. But i want to embid this in my mxml applcation. If anybody
    have idea, please reply me.
    Thanks again.

  • How to Load a SWF in Dynamically Loaded HTML

    Hello,
    I have a Flash movie with a multi-line text field that loads
    HTML text. As per the below Macromedia documentation I have swfs as
    images inside my HTML text.
    I'm trying to find a way to pre-load these swfs - if I do
    loadmovie to load the swf, when the html file is loaded will it
    need to reload the swf from scratch or will it take my loaded
    version? I'd love to show a "loading" message in the text as the
    swf was loading but am unsure how to do this now that I have the
    swf reference embedded in the html text.
    Any ideas?
    Thanks!
    Julia
    From the Macromedia documentation:
    Image tag (<img>
    The <img> tag lets you embed external JPEG files, SWF
    files, and movie clips inside text fields. The <img> tag has
    one required attribute, src, which specifies the path to a JPEG
    file, a SWF file, or the linkage identifier of a movie clip symbol.

    Thanks - your answer is exactly what I was looking for.
    I'm noticing that every swf I load via dynamic HTML is
    distorted - is there a way to prevent this? I can set the width and
    height of each swf in the HTML, which works ok, but then I run into
    a problem when I try and have a component item (like an accordion)
    included in the dynamic text field. It works properly, and the
    framing is sized correctly, but the guts are still skewed. I
    haven't been able to figure out why the swfs are being distorted in
    the first place.
    Any ideas?
    Thanks,
    Julia

  • "JavaScript Error encountered while loading HTML"

    Hi,
    I have been trying to embed a google map on a InDesign CC page, NO LUCK YET.
    I spoke several Adobe InDesign help line people, unfortunately they couldn't solve it.
    Here is the problem: I tried with different versions
    1- version) I copy of a map code and paste the code on a page, shows grey square round image and nothing (no map)
    2- version) From Object menu:
        "Select insert HTML.."
        "This is an HTML snippet."
    I paste the codes into HTML box, a second later, small box message,
         "JavaScript Error encountered while loading HTML"
    I have 64bit 12gb ram computer with windows 8.1
    InDesign CC version 9.2.1 x64
    Java 7 update 51
    I have tried with Internet explorer, google chrome and fire fox, and different maps, still no luck.
    Can anyone solve this problem?
    Thank you in advance,
    atamtan

    Yes, Google changed something and not for the better.
    Try a bing map instead. They work fine.

  • Why does DW CC 2014.1 Fluid Grid load HTML file that contains Google Analytics Tracking Code script so slowly?

    I exclusively work in Fluid Grid since my site is a Responsive Web Design.  I'm having trouble with slow load time in DW CC 2014.1, when my file, as they all do of course, has the Google Analytics Tracking Code script.
    I'm on a Windows 8.1 using a Dell Precision M3800 Laptop with Memory 16GB (2x8GB) 1600MHz DDR3 . Each of our site's 180 or so web pages, of course, has its Google Analytics Tracking Code script. It is placed, following Google instructions, as the last entry in the <head>.  Google Analytics does not instruct to place the script in the JS Folder with an scr to it, but rather in the <head>.  It takes up to one and a half or two minutes for DW CC 2014.1 to load the Google Analytics Tracking Code script .  That is, the grid does not show in Live View until finally analytics.js shows up in the Document Toolbar. A minute or two can add up when every page you load takes this long.  And, making new Fluid Grid pages, as is done, through the Save As command; every new page made you have to deal with the minute or two wait time since all those pages have the Google Analytics Tracking Code script.  Therefore, this time component alone, assuming I'm accessing and/or making 20 pages per week (and in our business this is easily the case) the math is that I'm wasting between 17 and 35 hours per year just with DW CC 2014.1 loading the much needed Google Analytics Tracking Code script.
    I have loaded HTML files that do not have the Google Analytics Tracking Code script as a test and those files load at the normal quick speed.
    Therefore, the new Chromium Embedded Framework browser engine has a serious load problem when it confronts an HTML5 file with a Google Analytics Tracking Code script.  Oddly, the prior DW CC 2014 version, with the old browser engine did not have this slow-load problem since I was loading these same files in that DW CC version up until October 8th or so.
    I think this new browser engine is a Google platform that apparently has a problem rendering or loading a Google Analytics Tracking Code script.  That makes no sense.
    Anyone else had this particular slow-load problem with DW CC 2014.1?
    Thanks.

    Wow.  That sure solved the slow-load problem, at least using your suggested snippet in a simple test HTML file.
    Per Google's instructions, I pasted the snippet before the closing </head> tag.  And, even in that positioning in the file; the file loaded at the speed (about one second) that it did prior to DW 2014.1.
    Two questions.
    Will this snippet provide the same tracking data as my current GA snippet?
    Because my current GA snippet is in about 200 web pages, can I retain the old snippet in most of them and place the new snippet in my approximately 5 main web pages as well as my templates so my new pages, as well as my main pages, have the new snippet.  That is, can I have both snippets (i.e. old snippet in earlier pages and new snippet in main pages and new pages to be made going forward) in my website at the same time?
    Of course I would not have both the old and new snippet in a web page at the same time.
    I greatly appreciate any assistance anyone can provide me on this issue and thank all of you in advance.
    I've provided code for both simple test files below.
    Code for Asynchronous Syntax of GA script:
    <!doctype html>
    <!--[if lt IE 7]> <html class="ie6 oldie"> <![endif]-->
    <!--[if IE 7]>    <html class="ie7 oldie"> <![endif]-->
    <!--[if IE 8]>    <html class="ie8 oldie"> <![endif]-->
    <!--[if gt IE 8]><!-->
    <html class="">
    <!--<![endif]-->
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Test Asynchronous GA Tracking Code In Head</title>
    <link href="css/boilerplate.css" rel="stylesheet" type="text/css">
    <link href="/css/style.css" rel="stylesheet" type="text/css">
    <!--
    To learn more about the conditional comments around the html tags at the top of the file:
    paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/
    Do the following if you're using your customized build of modernizr (http://www.modernizr.com/):
    * insert the link to your js here
    * remove the link below to the html5shiv
    * add the "no-js" class to the html tags at the top
    * you can also remove the link to respond.min.js if you included the MQ Polyfill in your modernizr build
    -->
    <!--[if lt IE 9]>
    <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <script src="js/respond.min.js"></script>
    <script type="text/javascript">
      var _gaq = _gaq || [];
      _gaq.push(['_setAccount', 'UA-73425000-1']);
      _gaq.push(['_trackPageview']);
      (function() {
        var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
        ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
        var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
    </script>
    </head>
    <body>
    <div class="gridContainer clearfix">
      <div id="div1" class="fluid">
        <div id="test1" class="fluid ">This is the content for Layout Div Tag "test1"</div>
       <div id="test2" class="fluid ">This is the content for Layout Div Tag "test2"</div> 
    </div>
    </body>
    </html>
    Code for older GA script snippet:
    <!doctype html>
    <!--[if lt IE 7]> <html class="ie6 oldie"> <![endif]-->
    <!--[if IE 7]>    <html class="ie7 oldie"> <![endif]-->
    <!--[if IE 8]>    <html class="ie8 oldie"> <![endif]-->
    <!--[if gt IE 8]><!-->
    <html class="">
    <!--<![endif]-->
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Test GA Tracking Code In Head</title>
    <link href="css/boilerplate.css" rel="stylesheet" type="text/css">
    <link href="/css/style.css" rel="stylesheet" type="text/css">
    <!--
    To learn more about the conditional comments around the html tags at the top of the file:
    paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/
    Do the following if you're using your customized build of modernizr (http://www.modernizr.com/):
    * insert the link to your js here
    * remove the link below to the html5shiv
    * add the "no-js" class to the html tags at the top
    * you can also remove the link to respond.min.js if you included the MQ Polyfill in your modernizr build
    -->
    <!--[if lt IE 9]>
    <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <script src="js/respond.min.js"></script>
    <script>
      (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
      (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
      m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
      })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
      ga('create', 'UA-73425000-1', 'auto');
      ga('send', 'pageview');
    </script>
    </head>
    <body>
    <div class="gridContainer clearfix">
      <div id="div1" class="fluid">
        <div id="test1" class="fluid ">This is the content for Layout Div Tag "test1"</div>
       <div id="test2" class="fluid ">This is the content for Layout Div Tag "test2"</div> 
    </div>
    </body>
    </html>

  • Some email images do not show while using the icloud web app.  I can see the images on my IOS devices and in gmail but I only see a small gray box in the icloud web mail app.  Load HTML images is checked in preferences.

    Some email images do not show while using the icloud web app.  I can see the images on my IOS devices and in gmail but I only see a small gray box in the icloud web mail app.  Load HTML images is checked in preferences.  Is there a solution to this issue?

    I've seen the opposite issue.  My wife recieved an email with jpg attachments.  She couldn't see or print them on her iPhone 4S but they showed up fine in iCloud or in the mail app.  I had her forward the email to herself and then they showed up.  I assume there is an issue with how Apple is processing the attachments and resending causes them to get reformatted in a way that makes them easier to handle.
    So yeah.  Seems like some bugs.  Hope Apple fixes them soon.

  • How to create a popup window to load HTML page in AIR application without using any mx or spark?

    How to create a popup window to load HTML page in AIR application without using any mx or spark components?
    I need to load the HTML page in popup in AIR application without using any of the <mx> or <spark> components. I need to open in the application itself not in the browser.(If we use navigateToURL() it will open in th browser)

    Can we achieve this? can somebody help me on this scenario..

  • How to load html page or website in flash as3

    hi
    how to load html page or web link (www.google.com)  in flash as3.
    please help me...

    Use the navigateToURL function...
    var url:String = "http://www.wherever.com";:
    var req:URLRequest = new URLRequest(url);
    navigateToURL(req);
    OR in one line...
    navugateToURL(new URLRequest("http://www.wherever.com"));

  • How to load Html page in Flex 4 application

    Hi All,
              I am able to load html page in flex 3 application but i am unable to load in flex 4 application.
    How can i do it.
    Can any help me regarding this.
    Thanks in Advance
    Raghu.

    This may help - http://www.deitte.com/archives/2006/08/finally_updated.htm
    Thanks and Best regards,
    Pallavi Joshi | [email protected] | www.infocepts.com

  • How to load html web in flash?

    How to load html web inside flash as2/as3?

    Hi spoboyle, thanks for your reply!
    Will the above methods works for a web app if I want to load something like these in flash?
    <iframe src=http://www.flickr.com/slideShow/index.gne?group_id=71332142%40N00 frameBorder=0 width=500 height=500 scrolling=no></iframe>
    or maybe this
    <object width="400" height="300"> <param name="flashvars" value="offsite=true&lang=en-us&page_show_url=%2Fphotos%2Fabefilm%2Fsets%2F74457524564396771%2Fshow%2F&page_show_back_url=%2Fphotos%2Fabefilm%2Fsets%2F7215 7622564396771%2F&set_id=72121762456636771&jump_to="></param> <param name="movie" value="http://www.flickr.com/apps/slideshow/show.swf?v=109615"></param> <param name="allowFullScreen" value="true"></param><embed type="application/x-shockwave-flash" src="http://www.flickr.com/apps/slideshow/show.swf?v=109615" allowFullScreen="true" flashvars="offsite=true&lang=en-us&page_show_url=%2Fphotos%2Fabefilm%2Fsets%2F72153224564396771%2Fshow%2F&page_show_back_url=%2Fphotos%2Fabefilm%2Fsets%2F72237624564396771%2F&set_id=72427624564396771&jump_to=" width="400" height="300"></embed></object>
    UPDATED: I downloaded the wrapper and read the README and docs. Im still unable to use it, how do I use it inside my flash to load html?

  • Loading HTML/WORD Documents in Oracle8i

    How do we Load HTML/Word or other content Documents in Oracle8i Database.
    And is there a GUI interface available to insert documents.
    Genereal users cannot probably use SQL Loader for that
    Replies urgetntly required so please kindly mail to [email protected]
    thank you
    -nandeep

    This is documented in http://technet.oracle.com/doc/oracle8i_816/inter.816/a77063/cdefaul5.htm#1000908
    examples in http://technet.oracle.com/doc/oracle8i_816/inter.816/a77063/aload.htm#272
    easiest is INSERT, frequently done when http-posting text from an html form into a varchar2
    iFS also provides several text insert methods.

  • Is it possible to load HTML data into BW?

    Is it possible to load HTML data into BW,I have read in some places that is is possible but I cannot find much documentation on this on Google or other SAP sources.
    If anyone has some documentation or general how-to guides that would be great!
    Even a general overview in your own words would be a great starter.
    Thank You
    Points will be assigned

    Please check these links n see if it helps
    http://help.sap.com/saphelp_nw2004s/helpdata/en/78/ef1441a509064abee6ffd6f38278fd/frameset.htm
    http://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/icc/bw-udc-jdbc%20universal%20data%20connect%20jdbc%20interface.pdf
    http://help.sap.com/saphelp_nw04/helpdata/en/00/f01640dc88e769e10000000a155106/content.htm
    Regards,
    R.Ravi

  • Is It possible to load Html page inside Adobe Flash...?

    Hi Everyone!
    Is It possible to load Html page Inside Adobe Flash CS5.
    Any help would be a great help...!
    Originally, i wanted to bring in through <IFRAME> but i don't see that flash understands that.
    Thanks in advance!
    -yajiv

    Not exactly sure how you where planning to display that HTML content in relation to the overall page, but given the limitations of Flash... that may just not be possible...
    But, it would be a simple matter to display an HTML iframe over the top of or behind a Flash .swf... So while the iframe would not be a part of the .swf, it certainly could be designed to make it look as though it were.
    Controling the stacking order or layering of content on a Web page is accomplished through z-indexing. Correctly positioned and z-indexed, the iframe could apear over the top of the .swf... the .swf in effect being the background... OR the iframe could appear behind the .swf and with a transparent section in the .swf, the iframe would appear through that hole. If there is navigation or links in the iframe, they will be blocked by the .swf though.
    http://www.w3schools.com/cssref/pr_pos_z-index.asp
    But this may be an option....
    Best wishes,
    Adninjastrator

  • Is It possible to load Html page inside Adobe Flash Professional..?

    Hi Everyone,
         Is It possible to load Html page inside Adobe Flash Professional or Adobe Flex. Thanks in Advance.
    -Vijay

    probably not the way you are thinking.
    flash textfields and their extensions have a limited number of html tags they can parse so, in general, html from most web pages will not display, as expected in flash.

  • Why Mail can´t load html images when it should?

    Hi, This is odd: Mail 6.2 seems unable to load html images on e-mail received even if the preference is set properly. Any clue?

    not at all. It happens since I´ve upgraded to Mountain Lion a few days back

Maybe you are looking for

  • Using Adobe Lightroom with OSX Photos

    I love the iCloud integration of the new Photos app, it's really great having all my photos available on my phone. I also love the editing capabilities of Adobe Lightroom. Has anyone figured out a way of using Photos for the iCloud integration and Li

  • Error while doing migo for STO order

    hi, we have done migo wrt the outbound delivery number and due to wrong invoice values they have cancelled the GR and again they are going to do the GR but system is not allowing to post the document since there is an entry in rg23d table with the sp

  • Problems with signed Applet for File Download under JRE 1.4 (works with 1.3

    Dear all, i encountered a very strange behaviour with JRE 1.4x. A signed applet used for file download worked on all platforms (Windows NT, 2000 and XP wth/wthout SP...) until I installed JRE 1.4.x (1.4.1 or 1.4.2) I get an EOFException when download

  • Regarding error handling in jsp

    how can i handle error in jsp page.That means i want to write error or exceptions in a file if an exception occurs.that meas i want to log that exception with time and date in a log file.how will i do?

  • Accessing system files on linux

    how do i get permission to access system files on linux?please help!