locked
Cannot run a Java applet in IE11 on Windows 10 RRS feed

  • Question

  • I am needing to run an applet in IE11 from my Windows 10 system. From what I've read this about the only browser with NPAPI support anymore so my options are pretty limited. I have successfully run this applet from an older system (laptop) that ran Windows 7 for several years but when I recently switched to a new laptop that is running Windows 10, I am unsuccessful in getting IE11 to load it.

    I have tried setting the Internet Security Options to allow ActiveX to launch but still I get a IE Add-on Installer - Security Warning with the message - "Windows has blocked this software because it can't verify the publisher."

    If this isn't the right place to ask this question, please let me know how where I should seek help.

    Thanks

    Tuesday, May 19, 2020 2:15 PM

All replies

  • Hi JimJamFlimFlam,

    You need to check several things. 

    I suggest you refer to the steps below to check whether applet script execution is enabled in the IE browser or not.

    1. Launch the IE browser.

    2. Click on the Tools (Alt + X) button.

    3. Go to the Internet options.

    4. Click on the Security tab.

    5. Select the security zone according to your site. (If you are accessing the site from internet then choose the Internet zone, if you are accessing the site from intranet then select the Local intranet zone).

    6. Click on Custom Level button.

    7. Scroll to the option 'Scripting of Java applets'. It is located under scripting category.

    8. Enable it.

    Next thing, we need to configure the security settings in Java control panel.

    Please refer to the steps below.

    1. Open control panel on your Windows 10 machine.

    2. Click on Programs.

    3. You will see the Java app icon there.  Click on it.

    4. It will launch the Java control panel.

    5. Go to the Security tab in it.

    6. Checked the checkbox for Enable Java contents for browser and web start application.

    7. Select the security level as High.

    8. You need to add your site in Exception site list.

    9. Click on Edit site list button.

    10. Add your site and make sure that your site is using HTTPS protocol.

    11. click on OK button to close the dialog.

    12. Click on Apply button and then click on OK button.

    After making above changes, I created below java file.

    First.java

    import java.applet.Applet;  

    import java.awt.Graphics;  

    public class First extends Applet{    

    public void paint(Graphics g){  

    g.drawString("welcome",150,150);  

    }    

    }  

    I compiled the file using Javac command.

    Then I referenced the generated class file in the HTML code.

    myapplet.html

    <html>  
    <body>  
    <applet code="First.class" width="300" height="300">  
    </applet>  
    </body>  
    </html>  
    I try to host the class file and HTML file on IIS server.

    I visit the site in the IE browser and you can see that it displays the Welcome text.

    You can try to refer to the above steps and let us know whether it works for you or not.

    Regards,

    Deepak 



    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, May 20, 2020 7:17 AM
  • Deepak,

    Thank you for the detailed reply. I am not set up to use HTTPS in my test environment. Is that a requirement?

    Thursday, May 21, 2020 11:11 AM
  • Hi JimJamFlimFlam,

    It is mentioned in the Java Control Panel that File and HTTP protocols are considered a security risk. It is recommended to use HTTPS.

    I also make a test using File and HTTP protocols but it is not working on my side. Only the page with HTTPS protocol is able to run the Applet code.

    So I suggest you add the HTTPS protocol and make a test with it to see whether it helps to solve the issue.

    Regards,

    Deepak


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, May 22, 2020 1:18 AM