Netscape Window Resize/Applet Reload Problem

Is there anyway to keep a java applet from restarting when a Netscape window is resized? This problem doesn't happen in IE.

In my case, someone told me to eliminate in applet's HTML this directives:
<META HTTP-EQUIV="Pragma" CONTENT="No-cache">
<META HTTP-EQUIV="Cache-Control" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="0">
<META HTTP-EQUIV="Cache-Control" CONTENT="must-revalidate">
<META HTTP-EQUIV="Cache-Control" CONTENT="mag-age=0">
Further, to set in Preferences/Advanced/Cache the option "Once per session" for "Document in cache is compared to document to network"
Believe me, in my case, it's worked with no aditional changes in the original applet's code. (Don't thank to me, my chilean friend Christian was the magician).

Similar Messages

  • Applet Reloading problem

    Hi,
    I am involved in a project in which we are using many images to scroll in a applet.The url of the images are retiriving from the data base and given to the applet using jsp.The problem is when the page is reloaded it takes much time to show the applet again even i am using the archive tag.Can any one tell me how to get rid of this reloading problem.
    Regards,
    Prakash

    Hi,
    Thanks for the reply.Actually i am not reloading the page.when i go to some other page and comes back it takes a long time ro load the page.Is there any way to overcome this problem.
    Regards,
    Prakash

  • Applet reload problem

    How can one ensure that an applet re-initialise itself when returning to the applet's page after leaving to other pages.
    I can only force to reload by pressing ctrl and refresh botton on the browser. Is there any tricks that can bypass this procedure and reload the applet automatically when one re-enter the applet's page?
    Thanks for any great suggestion.

    I think that JavaScript can be very useful if you wish to establish communication between your Applet and your browser.
    JavaScript -- > Java communication does not require the use of any particular API
    You just neet to clearly specify the name of your applet like this :
    (I prefer to use OBJECT tag than APPLET... is more generic)
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" name="myApplet" width="230" height="360" align="baseline">
    <PARAM name="code" value="myApplet.class">
    <PARAM name="type" value="application/x-java-applet">
    <PARAM name="scriptable" value="true">
    </OBJECT>Check out the scriptable parameter. This is required for Java --> JavaScript communication.
    Now, let's say you want a call a method called setMyAppletName that you have implemented in your applet, you would call it from a JavaScript function like this :
    function callJavaMethod(){
    document.myApplet.setMyAppletName("myApplet");
    }Notice that parameter name in your tag insertion tags should match the name of the applet you're tring to acces in the JavaScript function.
    Java -- > JavaScript communication it's a bit more complicated. It requires the use of netscape libraries that you can find in the following path of your Netscape install :
    [your Program Files directory ]\Netscape\Communicator\Program\java\classes
    There you will need a jar file called java40.jar (this is what I have with Netscape 4.7) where netscape packages are found. After having isntalled this jar in my package directory, this is how I refer to API
    import netscape.javascript.*;
    //Reference to browser window where current applet is embedded
    JSObject jsoWindow = JSObject.getWindow(this);
    //Preparing parameters to be sent to a JavaScript function that is going to be called
    String strHelloMsg = "Hello";
    //Parameters neet to be stored in a String array in order to be passed to JavaScript function
    String[] strArrParams = {strHelloMsg };
    //Init JavaScript function name to be called
    String strFunctionName = "showMessage"
    //Call JavaScript function
    _jsoWindow.call(strFunctionName, strArrParams);In your HTML page you could define such function like this :
    <script>
        function showMessage(strMsg){
                alert(strMsg);      
    </script>That's all the help I can give since I don't know how JavaScript browser events work. You should find it out in the huge amounts of JavaScript tutorial and reference sites.
    Good luck !
    Diego

  • Applet running problem in ie 6.0 under Windows XP

    Applet running problem in ie 6.0 under Windows XP
    I have a PC running Iternet Explorer 6.0 running under Windows XP. I have developed an applet using JDK 1.3 which is running fine with applet viewer , but it is not running in ie. I have installed Netscape navigator and Opera 5. the applet is running fine in both of these browsers but somehow it is not running in IE.
    Later on I upgraded my JDK to 1.4. It also displays use Java2 (V1.4.1) for <applet> (requires restart) tck marked in Advance section under Tools-Options menu of IE.
    I have also tried and set various options in my Control Panel�s Java Plug-in but all in vain. I have searched the sites for this solution but no one answers specifically.
    I know it�s a small problem due to discarded JVM in IE under Windows XP but give me solution for that.
    Thanks in Advance
    [email protected]

    Dear I have the same problem .
    Applet running problem in 6.0 . Enen I have installed the latest Jre 1.5.
    What should I do. I am fedup with this problem.

  • Problems with Photoshop CS2 I originally purchased this software several years ago. At time I was running Microsoft Windows XP. This computer recently was replaced with  a Dell running Windows 8.I reloaded my CS2 on this computer & it ran fine with a few

    Problems with Photoshop CS2
    I originally purchased this software several years ago. At time I was running Microsoft Windows XP.
    This computer recently was replaced with a Dell running Windows 8.I reloaded my CS2 on this computer & it ran fine with a few exceptions as follows;
    when the software comes up initially I get a message that says “could not complete your request because of program error”. Hitting OK allows me to continue using the software .
    When I try to activate a function using CTLR or ALT keys I get this message “required application failed to load and the product cannot continue. Please reinstall the application”. This causes the application to abort.
    Reloading my CS2 continues to generate the same messages when I depress the CTLR or ALT keys.

    Your original copy is obsolete and Adobe is offering a free replacement you are entitled to. Download and use that and that should clear it up for you.
    https://helpx.adobe.com/x-productkb/policy-pricing/creative-suite-2-activation-end-life.ht ml
    Download this copy of CS2 and use the serial number provided next to the download link.

  • [SOLVED] GNOME 3.8 annoying window resize problem

    Hello all fellow early-adopters :-)
    A very annoying quirk I've noticed, moving from GNOME 3.6 to 3.8, is that it no longer remembers, nor retains, the size/positions I set for many of my application windows. For example, my mail client (Evolution) is sized to fill most of my screen (centrally), with Empathy and Skype as long narrow windows on both sides - giving me a nice, broad "communications" overview on that particular desktop (with dev tools etc open on others).
    On 3.6, this layout was retained during my session, as well as next time I started these apps up.
    In GNOME 3.8, not only does it insist that these windows are always started as small little bunched-up windows that I need to resize, but every time a window displays a notification/warning (message in internal yellow bar inside the window - such as loss of internet connection, mail retrieval failure etc) it resizes the windows spontaneously to a stupid, small size that overlays the other windows. This is driving me crazy!
    Where can I learn a bit more about how window sizing / positioning works in GNOME 3.8, or is it finally time to switch to awesome wm? I want to love GNOME 3.8, I really do. It's so slick, but so... unpolished.
    I want to dig in an assist with problems like these, but I need some pointers to some background material first to understand the problem. Is it the window manager? Is it the app?
    ** UPDATE: Doing a full system upgrade, as of May 18, 2013, has resolved this annoying problem. My windows now stay where they belong, and start with the same size they were closed with. GNOME is now pleasant to use again :-)
    Last edited by dawid.loubser (2013-05-21 13:37:25)

    dawid.loubser wrote:Thanks for the suggestion drtebi - I'll give it a try.
    I really like GNOME 3.x though (and would like to understand the windowing behaviour), but if the annoying quirks are insurmountable, I will happily switch.
    Man I love GNOME 3.x. I admire the courage they had to change, basically, everything, and I find myself more productive with my GNOME 3 Arch box than with my good ol' Slackware KDE 4 box. I just hate those bugs - for example I filed a task in their bugtracker for this window resize problem I have with gedit. If it's a love/hate relationship, I think it's marriage ^_^
    With the 3.8 upgrade, deadbeef was having a similar problem with window size/position. I just recompiled it against the latest GTK+3 package upgrade (that came after the 'big upgrade' here on Arch) and it was fixed. But not with gedit
    bwat47 wrote:
    Man I really hope this gets fixed soon, because aside from this one incredibly annoying issue I am loving gnome 3.8.
    I get the feeling gnome badly needs more beta testers, sizable regressions like this in "stable" releases happen way too often sad.
    I get the exact same feeling. Well bugs exist everywhere, there's no denying. But I think it would be wiser to 'alternate' the nature of each major stable release - one focusing on new features and one focusing on fixing bugs. For example if the only new features in GNOME 3.10 were the AppsFolder full implementation and the introduction of gnome-calendar, and the rest of the development cicle being devoted to fix bugs, I'd be more than happy.
    Like Fedora and Ubuntu, the fixed 6-month release cycle colaborates with the bugs. They don't do like Debian or Slackware which are released 'when they are ready'.
    EDIT: fout (yet) another bug. At least with facebook chat (haven't tested with other telepathy plugins) the buddy tray icon appear duplicate. Anybody with the same issue?
    Last edited by lmello (2013-05-02 14:06:06)

  • Applet ClassLoader Problem

    Hi all,
    I experienced a problem which I couldn't solve yet. My applet depends on some third party libraries which are located in a lib/ folder, therefore the archive tag looks like that:
    archive="MyApplet.jar,lib/thirdParty1.jar,lib/thirdParty2.jar..."The applet folder consist of: lib/ MyApplet.html MyApplet.jar
    If I start the html file from this folder everything works fine, but if I deploy the applet with my webapp to Tomcat and start the applet from a button ( window.open("Applets/MyApplet.html","", att)) the classloader will not find the third party libraries and a java.lang.NoClassDefFoundError exception is thrown(Java Console).
    Any advice is highly appreciated.
    Stephan

    I still don't have a clue what is going on here. In the lib/ I have five third party libraries, three are loading and two throwing above mentioned error. I have downloaded the libraries again compiled my applet and my web app, even signed all jars, but same thing. This is true on Linux and WindowsXP for Firefox, Netscape and IE. I'm using java version 1.5.0_06.
    Any help is highly appreciated.
    Stephan

  • Applet- Reload

    Applet->Reload result in closing of applet window... It calls....
    stop()->destory()->init()->start() . Still window is not displayed.
    Have i missed something ....
    Applet that i have created is the simplest of Applet with only print statemetns inside init(), start().......

    Hello Roger,
    thanks for your answers. I was talking about FF3 and the java sun 1.6 that
    came with ubuntu 8.04, and iirc fedora. But also epiphany under ubuntu 8.04
    and fedora with FF3 (current version, already removed it again) have troubles.
    Meanwhile I tried the new OpenJDK version and this one does not have the
    reload-problem. I noticed that combinations of FF2/Solaris FF2/Linux FF2+3/Win
    have no problems at all (all running some 1.6 versions).
    Thanks also for telling me about the 6u10 release, I realy wasn't aware of it. But
    my problem is not to make an applet working for myself. I want to develop an
    applet for others, I want to make it work with any version of java - and what I
    want is not so special, just 2 textareas and a bunch of buttons, reliable operational.
    So I will not try the 6u10 for now because even if it would work it wouldn't
    help me.
    Applets dying because of a page reload is - as I think - a horrible bug and I
    don't understand why such bug reports are a week later still marked as
    "unconfirmed" or "new". But I'm talking about mozilla bugs, so I'm probably
    at the wrong place for complaining about that.
    Another thing is that, for instance, opera on ubuntu 8.04 running the sun java
    1.6 has another kind of problems with reloads, the applet looses the focus
    on reload, one must focus another non-opera window and than focus back to
    the opera window in order to give the input focus to the applet.
    All that is very annoying if you just want to develop a little simple applet for anyone.
    Best,
    Leander
    ps.
    Btw, all browsers like FF2+3/IE6+7/Safari/Opera and the sun java 1.6 work perfectly
    under windows :-/ so problems with three popular browsers running under one of the most
    popular distributions lets me think that there is something wrong with the java support
    under linux.
    pps.
    why is there still no 64bit browser plugin?

  • Pop up window resize disabled not working in fire fox (Linux)

    Hi all I am using Dreamweaver 8, with behavior I made a pop
    up window and disabled window resizing. It worked nicely in my
    windows XP system (I checked it in IE and Fire fox). But it is not
    working in Linux machine having same version of Fire fox
    browser(but worked correctly in IE on the same machine). In Linux
    machine we can simply resize the window.
    Does anybody give a solution to fix this problem?

    Post a link to the page, please.
    Why disable window resizing? What about those whose screen
    won't display
    the size you have picked?
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "thozhayan" <[email protected]> wrote in
    message
    news:egpsde$s3r$[email protected]..
    > Hi all I am using Dreamweaver 8, with behavior I made a
    pop up window and
    > disabled window resizing. It worked nicely in my windows
    XP system (I
    > checked
    > it in IE and Fire fox). But it is not working in Linux
    machine having same
    > version of Fire fox browser(but worked correctly in IE
    on the same
    > machine). In
    > Linux machine we can simply resize the window.
    >
    > Does anybody give a solution to fix this problem?
    >
    >

  • Node Container that does not resize with Window Resize Event

    Hello,
    I'm not new to Java but I am new to JavaFX.
    I plan to have a container/Canvas with multiple shapes (Lines, Text, Rectangle etc) in it. This Container can be X times in the Szene with different Text Shapes. I need to Zoom and Pan (maybe rotation) the whole Szene and the Containers/Canvas.
    So I was playing around with that but I have two issues.
    1) all Canvas classes that I found (like Pane for example) do resize with the main window resize event. The content of the canvas isn't centered any more.
    2) I added a couple of Rectangles to the canvas and both the rectangles and the canvas have a mouse listener which will rotate the item/canvas. Problem is, that even if I click the rectangle also the underlaying canvas is rotated...I think I need some kind of Z-Info to find out what was clicked.
    Here is the little example program, it makes no produktiv sense but it demonstrates my problem.
    Does anybody has a tip what canvas class would fit and does not resize with the main window and how to figure out what was clicked?
    public class Test extends Application
         Scene mainScene;
         Group root;
         public static void main(String[] args)
            launch(args);
        @Override
        public void init()
            root = new Group();
            int x = 0;
            int y = -100;
            for(int i = 0; i < 5; i++)
                 x = 0;
                 y = y + 100;
                 for (int j = 0; j < 5; j++)
                      final Rectangle rect = new Rectangle(x, y, 30 , 30);
                       final RotateTransition rotateTransition = RotateTransitionBuilder.create()
                             .node(rect)
                             .duration(Duration.seconds(4))
                             .fromAngle(0)
                             .toAngle(720)
                             .cycleCount(Timeline.INDEFINITE)
                             .autoReverse(true)
                             .build();
                     rect.setOnMouseClicked(new EventHandler<MouseEvent>()
                          public void handle(MouseEvent me)
                               if(rotateTransition.getStatus().equals(Animation.Status.RUNNING))
                                    rotateTransition.setToAngle(0);
                                    rotateTransition.stop();
                                    rect.setFill(Color.BLACK);
                                    rect.setScaleX(1.0);
                                    rect.setScaleY(1.0);
                               else
                                    rect.setFill(Color.AQUAMARINE);
                                    rect.setScaleX(2.0);
                                    rect.setScaleY(2.0);
                                    rotateTransition.play();
                      root.getChildren().add(rect);
                      x = x + 100;
        public void start(Stage primaryStage)
             final Pane pane = new Pane();
             pane.setStyle("-fx-background-color: #CCFF99");
             pane.setOnScroll(new EventHandler<ScrollEvent>()
                   @Override
                   public void handle(ScrollEvent se)
                        if(se.getDeltaY() > 0)
                             pane.setScaleX(pane.getScaleX() + 0.01);
                             pane.setScaleY(pane.getScaleY() + 0.01);
                        else
                             pane.setScaleX(pane.getScaleX() - 0.01);
                             pane.setScaleY(pane.getScaleY() - 0.01);
             pane.getChildren().addAll(root);
             pane.setOnMouseClicked(new EventHandler<MouseEvent>(){
                   @Override
                   public void handle(MouseEvent event)
                        System.out.println(event.getButton());
                        if(event.getButton().equals(MouseButton.PRIMARY))
                             System.out.println("primary button");
                             final RotateTransition rotateTransition2 = RotateTransitionBuilder.create()
                                  .node(pane)
                                  .duration(Duration.seconds(10))
                                  .fromAngle(0)
                                  .toAngle(360)
                                  .cycleCount(Timeline.INDEFINITE)
                                  .autoReverse(false)
                                  .build();
                             rotateTransition2.play();
             mainScene = new Scene(pane, 400, 400);
             primaryStage.setScene(mainScene);
            primaryStage.show();
    }Edited by: 953596 on 19.08.2012 12:03

    To answer my own Question, it depends how you add childs.
    It seems that the "master Container", the one added to the Scene will allways resize with the window. To avoid that you can add a container to the "master Container" and tell it to be
    pane.setPrefSize(<child>.getWidth(), <child>.getHeight());
    pane.setMaxSize(<child>.getWidth(), <child>.getHeight());
    root.getChildren().add(pane);and it will stay the size even if the window is resized.
    Here is the modified code. Zooming and panning is working, zomming to window size is not right now. I'll work on that.
    import javafx.animation.Animation;
    import javafx.animation.ParallelTransition;
    import javafx.animation.ParallelTransitionBuilder;
    import javafx.animation.RotateTransition;
    import javafx.animation.RotateTransitionBuilder;
    import javafx.animation.ScaleTransitionBuilder;
    import javafx.animation.Timeline;
    import javafx.animation.TranslateTransitionBuilder;
    import javafx.application.Application;
    import javafx.event.EventHandler;
    import javafx.geometry.Point2D;
    import javafx.scene.Group;
    import javafx.scene.Scene;
    import javafx.scene.input.MouseButton;
    import javafx.scene.input.MouseEvent;
    import javafx.scene.input.ScrollEvent;
    import javafx.scene.layout.Pane;
    import javafx.scene.paint.Color;
    import javafx.scene.shape.Rectangle;
    import javafx.stage.Stage;
    import javafx.util.Duration;
    public class Test extends Application
         Stage primStage;
        Scene mainScene;
         Group root;
         Pane masterPane;
         Point2D dragAnchor;
         double initX;
        double initY;
         public static void main(String[] args)
            launch(args);
        @Override
        public void init()
            root = new Group();
            final Pane pane = new Pane();
            pane.setStyle("-fx-background-color: #CCFF99");
            pane.setOnScroll(new EventHandler<ScrollEvent>()
                @Override
                public void handle(ScrollEvent se)
                    if(se.getDeltaY() > 0)
                        pane.setScaleX(pane.getScaleX() + pane.getScaleX()/15);
                        pane.setScaleY(pane.getScaleY() + pane.getScaleY()/15);
                        System.out.println(pane.getScaleX() + " " + pane.getScaleY());
                    else
                        pane.setScaleX(pane.getScaleX() - pane.getScaleX()/15);
                        pane.setScaleY(pane.getScaleY() - pane.getScaleY()/15);
                        System.out.println(pane.getScaleX() + " " + pane.getScaleY());
            pane.setOnMousePressed(new EventHandler<MouseEvent>()
                public void handle(MouseEvent me)
                    initX = pane.getTranslateX();
                    initY = pane.getTranslateY();
                    dragAnchor = new Point2D(me.getSceneX(), me.getSceneY());
            pane.setOnMouseDragged(new EventHandler<MouseEvent>()
                public void handle(MouseEvent me) {
                    double dragX = me.getSceneX() - dragAnchor.getX();
                    double dragY = me.getSceneY() - dragAnchor.getY();
                    //calculate new position of the pane
                    double newXPosition = initX + dragX;
                    double newYPosition = initY + dragY;
                    //if new position do not exceeds borders of the rectangle, translate to this position
                    pane.setTranslateX(newXPosition);
                    pane.setTranslateY(newYPosition);
            int x = 0;
            int y = -100;
            for(int i = 0; i < 5; i++)
                 x = 0;
                 y = y + 100;
                 for (int j = 0; j < 5; j++)
                      final Rectangle rect = new Rectangle(x, y, 30 , 30);
                       final RotateTransition rotateTransition = RotateTransitionBuilder.create()
                             .node(rect)
                             .duration(Duration.seconds(4))
                             .fromAngle(0)
                             .toAngle(720)
                             .cycleCount(Timeline.INDEFINITE)
                             .autoReverse(true)
                             .build();
                     rect.setOnMouseClicked(new EventHandler<MouseEvent>()
                          public void handle(MouseEvent me)
                               if(rotateTransition.getStatus().equals(Animation.Status.RUNNING))
                                    rotateTransition.setToAngle(0);
                                    rotateTransition.stop();
                                    rect.setFill(Color.BLACK);
                                    rect.setScaleX(1.0);
                                    rect.setScaleY(1.0);
                               else
                                    rect.setFill(Color.AQUAMARINE);
                                    rect.setScaleX(2.0);
                                    rect.setScaleY(2.0);
                                    rotateTransition.play();
                      pane.getChildren().add(rect);
                      x = x + 100;
            pane.autosize();
            pane.setPrefSize(pane.getWidth(), pane.getHeight());
            pane.setMaxSize(pane.getWidth(), pane.getHeight());
            root.getChildren().add(pane);
            masterPane = new Pane();
            masterPane.getChildren().add(root);
            masterPane.setStyle("-fx-background-color: #AABBCC");
            masterPane.setOnMousePressed(new EventHandler<MouseEvent>()
               public void handle(MouseEvent me)
                   System.out.println(me.getButton());
                   if((MouseButton.MIDDLE).equals(me.getButton()))
                       double screenWidth  = masterPane.getWidth();
                       double screenHeight = masterPane.getHeight();
                       System.out.println("screenWidth  " + screenWidth);
                       System.out.println("screenHeight " + screenHeight);
                       System.out.println(screenHeight);
                       double scaleXIs     = pane.getScaleX();
                       double scaleYIs     = pane.getScaleY();
                       double paneWidth    = pane.getWidth()  * scaleXIs;
                       double paneHeight   = pane.getHeight() * scaleYIs;
                       double screenCalc    = screenWidth > screenHeight ? screenHeight : screenWidth;
                       double scaleOperator = screenCalc  / paneWidth;
                       double moveToX       = (screenWidth/2)  - (paneWidth/2);
                       double moveToY       = (screenHeight/2) - (paneHeight/2);
                       System.out.println("movetoX :" + moveToX);
                       System.out.println("movetoY :" + moveToY);
                       //double scaleYTo = screenHeight / paneHeight;
                       ParallelTransition parallelTransition = ParallelTransitionBuilder.create()
                               .node(pane)
                               .children(
                                   TranslateTransitionBuilder.create()
                                       .duration(Duration.seconds(2))
                                       .toX(moveToX)
                                       .toY(moveToY)
                                       .build()
                                   ScaleTransitionBuilder.create()
                                       .duration(Duration.seconds(2))
                                       .toX(scaleOperator)
                                       .toY(scaleOperator)
                                       .build()
                      .build();
                       parallelTransition.play();
        public void start(Stage primaryStage)
             primStage = primaryStage;
            mainScene = new Scene(masterPane, 430, 430);
             primaryStage.setScene(mainScene);
            primaryStage.show();
    }

  • Gmail scroll down arrow is covered by Firefox 4 window resize icon

    I updated Firefox to version 4 and now the scroll down arrow for the main mailbox of Gmail is covered up by the window resizing triangle icon for Firefox at the bottom right on the window.
    The scroll down arrow is effectively made unavailable.
    This appears to be the only site that causes this problem.

    You can add the bottom back back to your screen, which will move the resize corner below the scroll arrows. Just go to the '''View menu''' > '''Toolbars''' and enable the '''Add-on bar'''.

  • Safari: SWF doesn't resize during window resize

    I'm seeing a resize problem with Safari and FP9 beta, at
    least when the SWF is loaded directly in the browser window without
    an HTML wrapper. When you resize the browser window, the app
    contents in the SWF don't change size until the window resize is
    complete. In other browsers (Camino, for example), the SWF contents
    resize as the window does.

    This bug has persisted for two years and four months, through three major OS releases and numerous incremental updates.
    Zooming Finder windows has been around since System 7, or was it 6, or earlier? How could nobody have noticed this?
    Apple seems to be incapable of fixing these silly little glitches.

  • Here's how you use JavaMail in a Netscape 4.x applet

    First of all... Sun has said that they are working on patching JavaMail for the next minor release so that it will be usable with Netscape.
    But for those with itchy pants... here's how you do to send mail from a Netscape 4.x applet without using the Java Plug-in.
    First of all... you'll need to sign the applet. Now I'm not so good with singing tools so I don't know if Netscape 4.x allows using Sun's signing tools. I used Netscapes own "signtool" just to be sure.
    You'll need to unjar activation.jar and mail.jar (or mailapi.jar plus smtp.jar). Use signtool to sign and jar your own classfiles plus those from the jar-files mentioned.
    This creates a small problem though: atcivation.jar and mail.jar has files in the META-INF directory. Netscapes signtool ignores these files. So you'll have to patch around that.
    Using the "sendfile.java" demo as basis... here's how you deal with the missing configuration files.
        // You'll have to request this privilige or Netscape will bolt on you.
        // If you need cross-platfor compatibility you'll need to wrap this up or IE
        // will be really cranky at this. Try by doing something you know
        // IE accepts but that Netscape don't. Catch the  exception as just an
        // Exception and do the following in the catch.
        try {
          PrivilegeManager.enablePrivilege("UniversalPropertyRead");
        } catch (netscape.security.ForbiddenTargetException e2) {
          System.out.println("Failed! Permission to read system properties denied by user.");
        } catch (Exception e2) {
          System.out.println("Failed! Unknown exception while enabling privilege.");
          e2.printStackTrace(System.out);
        // create some properties and get the default Session
        Properties props = null;
        props = System.getProperties();
        props.put("mail.smtp.host", mailhost);
        // The mailcap command map needs a missing
        // config file. So you'll have to hardwire the different
        // commands like this.
        javax.activation.MailcapCommandMap commandMap = new javax.activation.MailcapCommandMap();
        commandMap.addMailcap("text/plain;;          x-java-content-handler=com.sun.mail.handlers.text_plain");
        commandMap.addMailcap("text/html;;          x-java-content-handler=com.sun.mail.handlers.text_html");
        commandMap.addMailcap("text/xml;;          x-java-content-handler=com.sun.mail.handlers.text_xml");
        commandMap.addMailcap("multipart/*;;          x-java-content-handler=com.sun.mail.handlers.multipart_mixed");
        commandMap.addMailcap("message/rfc822;;     x-java-content-handler=com.sun.mail.handlers.message_rfc822");
        commandMap.addMailcap("image/gif;;          x-java-view=com.sun.activation.viewers.ImageViewer");
        commandMap.addMailcap("image/jpeg;;          x-java-view=com.sun.activation.viewers.ImageViewer");
        commandMap.addMailcap("text/*;;          x-java-view=com.sun.activation.viewers.TextViewer");
        commandMap.addMailcap("text/*;;          x-java-edit=com.sun.activation.viewers.TextEditor");
        javax.activation.MailcapCommandMap.setDefaultCommandMap(commandMap);
        // Now here is a really weird thing. This class - MimeUtility - will
        // be used later on. But the ClassLoader in Netscape seems
        // to be broken. I downloaded J2EE and fiddled with this class a bit.
        // It seems that the following line will get you around this problem.
        Object o = MimeUtility.class;
        try {
          // create a message
          Session session = Session.getDefaultInstance(props, null);
          session.setDebug(true);
          MimeMessage msg = new MimeMessage(session);
          msg.setFrom(new InternetAddress(from));
          InternetAddress[] address = {new InternetAddress(to)};
          msg.setRecipients(Message.RecipientType.TO, address);
          msg.setSubject("Message from scratchpad");
          // create and fill the first message part
          MimeBodyPart mbp1 = new MimeBodyPart();
          mbp1.setText(message);
          // create the second message part
          MimeBodyPart mbp2 = new MimeBodyPart();
          // attach the file to the message
          // This is not the same as the original.
          // The ByteArrayDataSource class helps you attach an arbitrary file-type.
          // The code for that is found here:
          // http://forums.java.sun.com/thread.jsp?forum=43&thread=73819
          DataSource ds = new ByteArrayDataSource(imageData, "image/gif", "image.gif");
          mbp2.setDataHandler(new DataHandler(ds));
          mbp2.setFileName("image.gif");
          // create the Multipart and its parts to it
          Multipart mp = new MimeMultipart();
          mp.addBodyPart(mbp1);
          mp.addBodyPart(mbp2);
          // add the Multipart to the message
          msg.setContent(mp);
          // set the Date: header
          msg.setSentDate(new Date());
          // send the message
          // Transport.send() will give you exception in Netscape.
          // Here is how you do what that method does.
          msg.saveChanges();
          com.sun.mail.smtp.SMTPTransport transport = new com.sun.mail.smtp.SMTPTransport(session, null);
          transport.connect();
          transport.sendMessage(msg, address);
          transport.close();     
        catch (MessagingException mex) {
          mex.printStackTrace();
          Exception ex = null;
          if ((ex = mex.getNextException()) != null) {
            ex.printStackTrace();
        }Enjoy
    /Michael

    Typical... i knew I'd fumble. There is one more thing you need to do.
    Download J2EE, source code edition and patch the file javax.mail.internet.MimeUtility.java
    Change the line
    InputStream is = javax.mail.internet.MimeUtility.class.getResourceAsStream("/META-INF/javamail.charset.map");...to...
    InputStream is = javax.mail.internet.MimeUtility.class.getResourceAsStream("/javamail.charset.map");Also, after you unjar the jarfiles and before you run the signtool, move the file META-INF/javamail.charset.map to the partent of the META-INF directory.
    /Michael

  • Open a new browser window from applet

    Anybody know how to open a new Netscape window by pressing a button in an applet? Which class handles it?
    Thanks a lot.
    wz

    http://forum.java.sun.com/thread.jsp?forum=54&thread=106906
    http://forum.java.sun.com/thread.jsp?forum=54&thread=272870
    http://forum.java.sun.com/thread.jsp?forum=54&thread=272829

  • Window resize issue (borderless form)

    Hello!
    Resizing window (height) programmically does not work correctly. Here's the problem in visual form:
    When resizing the window height from (715; 375) to (715;600) (or even to its MaximumSize (715; 660)) using commands as which are listed here, operation leaves parts
    of the bottom elements under the StatusStrip control bat. No matter if the window max height/height is set to say 800, always the same issue.
    Is it the missing borders behind the issue or is the StatusStrip height just unnoticed? Is there some solution available to get it resize correctly?
    (VC++ 2013.4, .NET 4.5x, Windows 7)

    OK, you can download the fPEQGUI-10MC project from
    http://jiiteepee.tripod.com/home.html (I couldn't get the build from this source to work properly in 64-bit Windows 10 so better try with 32-bit build).
    It's quite messy coding there but you should be able to repeat the issue by commenting (just use the find-replace feature) the graf_splitter and pref_splitter lines from methods (there's no window resize commands now but you can try by adding
    ones into these methods listed below):
    fWButton_Click,
    menu_options_preferences_file_write_interval_Click,
    menu_options_preferences_cutoff_freq_Click,
    initDefaults,
    setGainForRIAAFiltersToolStripMenuItem_Click,
    gui_show_graph_Click_1
    NOTE: You probably can't load the project into Designer because of I have edided all the font definitions by adding a font size multiplier (DPI scalar) in InitializeComponent() method (least I can't load without removing the multipliers).

Maybe you are looking for

  • How to pass a cursor as IN parameter to a procedure

    Hello I want to pass a cursor to a procedure as IN parameter. See the below piece of code: Cursor mycur is select * from table_name; Procedure myproc(mycur IN ...) begin fetch mycur into v_rec; {want to do some updates here} end; Please suggest how c

  • Why doesn't my iPhone notify me when I have a new text message?

    My iPhone 4S doesn't notify me when I get a new text message or iMessage. The phone is not in silent and the volume of the phone is at 10. I keep my phone near me all the time, I can hear the phone ring if it rings. Usually when I text someone, I sen

  • Location of imported files?

    I imported some raw files into aperture but wanted to access them outside of the library and cannot see where there were placed by aperture.

  • Registration of Suppliers

    Hello experts, We are looking to configurating Registration of Suppliers on the SUS client, and later use the preselect vendors in the EBP client for Bidding and Acution. Can any one please pass on any config document on Registration of Suppliers? Be

  • Connecting from linux to linux-help me on thjis asap please

    Hi all, I want to know how we conect linux machine from another linux machine remotely(This is basically for connecting home to office computer).In windows i used putty and used the following steps to connect it.But how do i do it in linux please adv