Java6 splash screen in java webstart

I can't get the java 6 splash screen working when running as a webstart application .
I don't mean the splash you get while downloading but the one that's been introduced in java 6 that's showing while your app is starting.
So far I tried adding it in the manifest file of the main jar, adding the classpath switch in the jnlp file , adding the classpath switch in the JAVAWS_VM_ARGS but none worked.
Is there any documentation on this ? Or how should it work ?
Bart

Here's a very simple version:
public class SplashScreen extends JWindow {
    public SplashScreen () {
      JLabel image = new JLabel(new ImageIcon(SplashScreen.class.getResource("icons/splash.gif")));
      this.getContentPane().add(image, null);
      this.pack();
      Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
      Dimension imageSize = image.getPreferredSize();
      this.setLocation(screenSize.width/2 - (imageSize.width/2),     screenSize.height/2 - (imageSize.height/2));
      this.setVisible(true);
}This assumes a sub-folder in the same folder as your SplashScreen class named icons, containing a file splash.gif.
You will need to dispose() of the SplashScreen object when you have finished with it.

Similar Messages

  • Splash Screen generates   java.lang.NoClassDefFoundError: Eapply errors.

    Hi Everyone,
    Again, I am new to Java (2nd month actually coding) and don't know of a better place to post this problem. Also, the forum does not have a search feature (that I can see) so I apologize if this issue has been raised and discussed before (which it probably has been).
    I am trying to utilize the new splash screen facility in SE 6 but have run into a problem. The image will display just fine but I get 'class not found' exceptions immediately afterwards. It seems as if the launcher cannot see the class containing main.
    I guess I need to mention the fact that I am using the Galileo version of Eclipse. I checked the project settings and confirmed that the class, in this case, Eapply, is in fact in the class path so I am at a loss as to why it cannot be found. My code reads pretty much like every example I have seen of the splash screen functionality, so I can only imagine that the problem lies within environmental settings or something else I am not taking into account.
    Here is the code I am using minus any lines not necessary to illustrate the problem:
    Command line
    -splash:images/vessels.jpg Eapply
    Class
    public class Eapply extends App implements ActionListener {
         public Eapply() throws SQLException {
              super("E-Apply Electronic Application", App.getCompanyID(), true);
         public static void main(String[] args) throws SQLException, ParseException {
              eapp = new Eapply();     
    The stack trace
    Exception in thread "main" java.lang.NoClassDefFoundError: Eapply
    Caused by: java.lang.ClassNotFoundException: Eapply
         at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:319)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:254)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:402)
    Any suggestions you can offer will be greatly appreciated.
    Thank You,
    Ricky

    RickyM wrote:
    I fixed the problem. Seems as if the classpath, while being launched within Eclipse, was correct. However, the classpath was not set correctly if you tried to launch the app from outside of eclipse. To fix the problem, I specified the -classpath option on the command line.That's a very typical problem, and one reason why IDE's should not become addictive to the point that you can't do anything without it. Yes the IDE handles setting the classpath for you. But of course the actual users running the software will not be using an IDE to run it, so you must become very acquainted with what the classpath is and how to use it.

  • How can i create splash screen using netbean?

    how can i create splash screen using netbean?

    Welcome to the Sun forums.
    gabbyndu wrote:
    how can i create splash screen..Java 6 offers a splashscreen functionality. See [New Splash-Screen Functionality in Java SE 6|http://java.sun.com/developer/technicalArticles/J2SE/Desktop/javase6/splashscreen/] *(<- link)* for details.
    [Java Web Start|http://java.sun.com/javase/technologies/desktop/javawebstart/index.jsp] has offered splash screens to applications since Java 1.2. See [How can I provide my own splash screen?|http://java.sun.com/j2se/1.5.0/docs/guide/javaws/developersguide/faq.html#206] in the JWS FAQ for more details.
    .. using netbean?We don't support Netbeans here. Ask that on a [Netbeans forum|http://forums.netbeans.org/].

  • To display splash screen for certian period of time using threads

    i want to write a program to display splash screen for certian period of time using threads. could some one help me

    If you just want a splash screen: [http://java.sun.com/developer/technicalArticles/J2SE/Desktop/javase6/splashscreen/|http://java.sun.com/developer/technicalArticles/J2SE/Desktop/javase6/splashscreen/]
    If you want to learn threads: [http://java.sun.com/docs/books/tutorial/essential/concurrency/|http://java.sun.com/docs/books/tutorial/essential/concurrency/]

  • Chromeless splash screen for application

    hi!
    Anyone know how to create a Chromeless splash screen for java application.Just like the startup screen for the normal application? When the java application start-up the screen will show, it's close after a few screen or user click a button.
    and is there anyway to add background image for a java application?
    Thank in advance!
    jet

    hi there, check a look at this code:
    import javax.swing.*;
    import java.awt.*;
    public class Splash implements Runnable, mainInterface{
    private String initMsg;
    public Splash(String initMsg) {
    this.initMsg = initMsg;
    public void run() {
    splashWindow.getContentPane().add(l, BorderLayout.CENTER);
    splashWindow.pack();
    splashWindow.setSize(splashWindow.getSize().width, splashWindow.getSize().height);
    splashWindow.setLocation(dim.width/2 - splashWindow.getWidth() /2,dim.height/2 -
    splashWindow.getHeight()/2);
    splashWindow.toFront();
    splashWindow.show(); }
    public JWindow getWindow()
    return splashWindow;
    }add this code to the main file
    private static void splash()
              th.start(); // I sleep to let the thread startup and display the window
                   while (splash3.getWindow() == null || !splash3.getWindow().isShowing())
                        try {
                             Thread.sleep(2000);
                        catch (InterruptedException e){}
         }hope u understand this
    asrar

  • Java 1.5 Update 6 Splash Screen

    I have a client who operates in a dark space and does not want bright white backgrounds or white splash screens. It is easy enough to use BGCOLOR="black" in the body tag of the applet containers. However, the Sun animated splash screen logo is my last challenge. I don't want to get rid of it so much as I want to color it a dark shade of grey or black. Anyone know if it is possible to darken the color of the background on the "Java Loading" splash screen ?

    You may have video problems. Check for the most current video driver version (from the video card provider, not the computer supplier.)

  • Urgent :::Icon in the Splash Screen of WebStart !!

    Hi !
    Java Web Start Version : 1.2
    I want to load an image in the Java Web Start's Splash Screen . I used the icon tag in the .jnlp file to do that .... but it's not getting loaded . here is the copy of my .jnlp file ....
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+" codebase="file:///D:/jdk06/bin/" href="image.jnlp">
    <information>
    <title>Test</title>
    <vendor>Self</vendor>
    <homepage href="http://www.sonic.net/~star" />
    <description>Demonstration of JNLP</description>
    <icon href="images/cuty10.jpg"/><!-- -----------------------------------------This image is getting loaded-->
    <icon kind="splash" href="icon.jpg"/><!-- ------------------------------------This image is not getting loaded-->
    <offline-allowed/>
    </information>
    <resources>
    <j2se version="1.3+" />
    <jar href="Baby.jar"/>
    </resources>
    <application-desc main-class="MyPictures" />
    </jnlp>
    only the image in the Splash screen is not getting loaded but the respective (Splash.xml) is created and also the image splashxyz.jpg is also created in the ..javaws\cache\splashes .
    Any Help Pls !!

    Thanks !
    Is there any restrictions that Splash Icons can be applied only to those JNLPs accesed via webservers ?
    ie .. if i have a JNLP and when i open it by double clicking , (ie the codebase in the JNLP file is reffered as file:///<system path> )the Splash Icon is not getting displayed . But when i try to open the same JNLP through weserver(tomcat)-http://localhost:8080/examples/jsp/demo/filename.jnlp ,(ie the codebase in the JNLP file is reffered as http://........) The Splash icon is appearing ...
    Is there any restrictions ????

  • Java Splash Screen

    Hey Everyone,
    I can't for the life of me get the Java SpashScreen to work. I have tried to run the example provided at [http://docs.oracle.com/javase/tutorial/uiswing/misc/splashscreen.html] however no matter how I try to run it i always get a java.lang.NoClassDefFoundError. Any ideas as to what I am doing wrong.
    I would eventually like to package my splash screen into a jar file for my application but first I would like to get the demo to work.
    Thanks,
    Nath5

    I think where you are going wrong is when you assume that error message has something to do with the fact that you're trying to use a splash screen. Since splash screens only display an image and don't require loading any classes, I would expect that messages about failing to load a class aren't related to your use of splash screens.

  • HT5945 new macbook pro loaded with mavericks. installed CS3 including prompted Java update. try to open photoshop &  empty splash screen pops up-can't go further. tried newer java update-same result. re-opened 4 times-same. help!!

    new macbook pro loaded with mavericks. installed CS3 including prompted Java update. try to open photoshop &  empty splash screen pops up-can't go further. tried newer java update-same result. shut down 4 times-same. any suggestions?

    Kappy wrote:
    Has it occurred to you that CS3 isn't compatible with Mavericks? Try using CS9 or 10.
    Sorry that's untrue. I have Photoshop CS3 running on 10.9.
    CS9 or 10? Now you are just making stuff up.
    Adobe claim CS3 will work, with a minor issue…
    http://helpx.adobe.com/x-productkb/global/mac-os-mavericks-compatability.html
    The Adobe updater fails to work for me.
    I was prompted to install J6RE which came from Apple, check the Apple support downloads http://support.apple.com/downloads/#java%206
    Sorry can't provide a direct link, it was just a dumb 'You need … please click install' dialog.
    I think the 10.9 java updater is installing version 7.

  • Webstart splash screen - test results required

    There is a thread on the JWS forum - [No splash screen in sight....|http://forums.sun.com/thread.jspa?threadID=5423155] in which we have been trying, unsuccessfully, to get a splash to appear for an app. I have begun to suspect there is a bug in the JWS client itself (it's a long time since I played with JWS splash screens - they used to work!).
    As preparation for raising a bug report, I created this small, sand-boxed demo to test the feature. You can find the test page (+links to all relevant files) at [http://pscode.org/test/splash/].
    I would appreciate finding out:-
    1) After following the 4 steps under 'Instructions for testing', did you see the splash for the second launch? Note that you should see the image, at least twice, displayed in the JFrame. I am not talking about that, but instead seeing the splash image floating over the desktop, without any window(/frame) decorations, in place of the usual Sun splash.
    2) What OS and Java version are you running?
    Note: Using Java 1.6 under Ubuntu, I do not see the splash image. :-(

    1) After following the 4 steps under 'Instructions for testing', did you see the splash for the second launch? Note that you should see the image, at least twice, displayed in the JFrame. I am not talking about that, but instead seeing the splash image floating over the desktop, without any window(/frame) decorations, in place of the usual Sun splash.
    2) What OS and Java version are you running?-----
    Yes, I am getting the same. It is showing the Image as splash screen without any border, frame or window over it. It also shows same image in another frame also. I think this the same as you are expecting.
    I am running
    java version "1.6.0_07"
    Java(TM) SE Runtime Environment (build 1.6.0_07-b06)
    Java HotSpot(TM) Client VM (build 10.0-b23, mixed mode, sharing)Over
    Microsoft Windows XP Professional

  • How can I customize the Java Report Panel applet splash screen?

    Has anyone found a quick and easy way, either via javascript or a webi properties file, to cutomize the splash screen for the Java Reporting Panel applet while it is loading?  I've found a few code snippets for the javascript approach, but they don't quite work, and apparently there's a webi properties file that I should be able to use to accomplish this, but where is it exactly?  Is it on the BO server, or should it be in a jar file in my project.  Can't seem to find it.  Thanks for any help.

    Look at the link I posted, you aren't double buffering correctly.
    I saw the other post you mistakenly made before you edited it. Not really a big deal, I was just wondering why you did that.

  • Custom splash screen for app under JWS 1.2 from 1.4.1 beta?

    Has anyone gotten a custom app's splash screen to come up instead of the damn Sun Java Web Start splash screen to come up when the app starts from a desktop icon or if you launch it from JWS?
    I added it to my jnlp file as specified in the docs, but it just doesn't come up :-(
    <description kind="tooltip">TransMedia 2</description>
    <icon kind="default" href="transmedia.gif" />
    <icon kind="selected" href="transmedia.gif" />
    <icon kind="disabled" href="transmedia.gif" />
    <icon kind="rollover" href="transmedia.gif" />
    <icon kind="splash" href="transmediasplash.gif" />
    </information>

    Hello,
    I read your postings here and I did what you proposed.
    Nevertheless the splash screen doesn't show up.
    I'm using Java 1.4.1, Web Start 1.2; the jnlp file
    looks like that:
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp codebase="http://venus/example-client/" href="example.jnlp">
    <information>
    <title>Example</title>
    <vendor>My Company/vendor>
    <description>JBoss Client</description>
    <icon href="splashscreen.jpg" kind="splash" />
    </information>
    <security>
    <all-permissions/>
    </security>
    <resources>
    <j2se version="1.4+"/>
    <jar href="example-client.jar" main="true"/>
    <jar href="jbosssx-client.jar"/>
    <jar href="concurrent.jar"/>
    <jar href="jboss-client.jar"/>
    <jar href="jboss-common-client.jar"/>
    <jar href="jboss-j2ee.jar"/>
    <jar href="jnp-client.jar"/>
    <jar href="log4j.jar"/>
    <jar href="datepicker.jar"/>
    <jar href="jcommon-0.7.1.jar"/>
    <jar href="jfreechart-0.9.4.jar"/>
    <jar href="xercesImpl.jar"/>
    <jar href="xml-apis.jar"/>
    <jar href="xalan.jar"/>
    <property name="java.security.auth.login.config" value="http://venus/example-client/auth.conf"/>
    </resources>
    <application-desc main-class="com.mycompany.ui.Example"/>
    </jnlp>
    any idea why webstart doesn't use the custom "splashscreen.jpg"?
    a properly splashXXXXX.jpg has been created in .javaws/cache/splashes, as well as an entry in splash.xml.
    thanx for help,
    michael

  • Custom splash screen not appearing in the Dynamic created jnlp()

    Hi,
    I am not able to show my custom splash screen while starting the webstart application, instead getting the "sun webstart logo". I am dynamically generating the jnlp file using jsp (struts application). Application is working perfectly except custom splash screen. Below is my jsp which will generate the jnlp on fly. The test.gif file is in place.
    <% response.setContentType("application/x-java-jnlp-file");
      response.setHeader( "Pragma", "no-cache");
      response.setDateHeader( "Expires", 0 );%>
    <%@ page import="java.io.*" %> 
    <%String baseURL = WebUtil.webUrlParser(request.getRequestURL().toString(),request.getContextPath(),request.getServerPort());%>
    <jnlp      spec="1.0+" codebase="<%=baseURL%>/cs_jnlp">
    <information>
        <title>Launching JNLP</title>
        <vendor>Satyasai</vendor>
        <icon href="/images/test1.jpg"/>
        <homepage href="docs/help.html"/>
       <description>test</description>
            <icon kind="splash" href="images/test.gif" />
       </information>
          <security>
            <all-permissions/>
         </security>
         <resources>
       <j2se version="1.6+"/>
       <jar href="<%=baseURL%>/cs_jnlp/AppLaunch.jar"/>
      </resources>
           <application-desc main-class="Launch" >
           <%
           int roleId = (Integer)session.getAttribute(Constant.USER_TYPE);
           String sessionID=(String)request.getAttribute("SELECTION_SESSION_ID");
           String action=(String)request.getAttribute("action");
           String userID = (String)session.getAttribute(Constant.LOGIN_ID);       
           String sessionType=(String)request.getAttribute("sessionType");        
           %>
           <argument><%=sessionID%></argument>
           <argument><%=action%></argument>
           <argument><%=userID%></argument>
           <argument><%=sessionType%></argument> 
    </application-desc>
    </jnlp>If I use normal servlet - jsp using RequestDispatcher to forward request to a jsp which on fly creates jnlp, it shows the my custom splash screen. I am not very sure where is the difference. If I look at both generated jnlps they are almost one and the same. Can any one throw some insight on this.
    Thanks & Regards,
    Satyasai

    Hi Andrew,
    Thanks for your response.
    1. I have launched it number of times but no luck.
    2. I have written a jsp (using servlet + jsp no struts frame work) which will create jnlp on fly, which is showing my custom splash screen. If you refer in the initial post, it is not working with struts kind of framework. See the below jsp which shows custom splash screen. It worked without href.
    3. All jnlps are well formed and perfectly working in my development environment. For security purposes I have not shown some of the texts and logos.
    <% response.setContentType("application/x-java-jnlp-file");
      response.setHeader( "Pragma", "no-cache");
      response.setDateHeader( "Expires", 0 );%>
    <%@page import="java.util.ArrayList" %>
    <%
    String client = (String)request.getAttribute("clientLocation");
    String fileNames = (String)request.getAttribute("filenames");
    String url= (String)request.getAttribute("serverFilesLocation");
    String baseURL = "http://"+request.getLocalAddr()+":"+request.getServerPort()+request.getContextPath();
    %>
    <jnlp spec="1.0+" codebase="<%=baseURL%>/sw_jnlp"> 
      <information>
        <title>Softwares Download</title>
        <vendor>test</vendor>
        <icon href="/images/test1.jpg"/>
        <homepage href="docs/help.html"/>
       <description>Software Downloads </description>
            <icon kind="splash" href="images/logo_small.gif" />
       </information>
       <update check="timeout" policy="always"/>
          <security>
          <all-permissions/>
      </security>
      <resources>
        <j2se version="1.6+"/>        
        <jar href="mod.jar"/>  
      </resources> 
      <application-desc main-class="InstallSW">
      <argument><%=client%></argument>
      <argument><%=fileNames%></argument>
      <argument><%=url%></argument>
      </application-desc>
    </jnlp>Thanks & Regards,
    Satyasai

  • Custom Splash Screen for HTML Export?

    We're finding our customers are getting confused with the HTML screen that initally displays a single button to play our Captivate lessons. Is there any way inside Captivate to add some context to that screen?
    TIA
    Retiarius

    Hello,
    I read your postings here and I did what you proposed.
    Nevertheless the splash screen doesn't show up.
    I'm using Java 1.4.1, Web Start 1.2; the jnlp file
    looks like that:
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp codebase="http://venus/example-client/" href="example.jnlp">
    <information>
    <title>Example</title>
    <vendor>My Company/vendor>
    <description>JBoss Client</description>
    <icon href="splashscreen.jpg" kind="splash" />
    </information>
    <security>
    <all-permissions/>
    </security>
    <resources>
    <j2se version="1.4+"/>
    <jar href="example-client.jar" main="true"/>
    <jar href="jbosssx-client.jar"/>
    <jar href="concurrent.jar"/>
    <jar href="jboss-client.jar"/>
    <jar href="jboss-common-client.jar"/>
    <jar href="jboss-j2ee.jar"/>
    <jar href="jnp-client.jar"/>
    <jar href="log4j.jar"/>
    <jar href="datepicker.jar"/>
    <jar href="jcommon-0.7.1.jar"/>
    <jar href="jfreechart-0.9.4.jar"/>
    <jar href="xercesImpl.jar"/>
    <jar href="xml-apis.jar"/>
    <jar href="xalan.jar"/>
    <property name="java.security.auth.login.config" value="http://venus/example-client/auth.conf"/>
    </resources>
    <application-desc main-class="com.mycompany.ui.Example"/>
    </jnlp>
    any idea why webstart doesn't use the custom "splashscreen.jpg"?
    a properly splashXXXXX.jpg has been created in .javaws/cache/splashes, as well as an entry in splash.xml.
    thanx for help,
    michael

  • Splash screen won't come up

    I have installed JWS and just did what was written in the document...but when I clicked on the link on my web page, it would print the information desciption on my .jnlp file. Not even the splash screen will come up, it was like JWS wasn't even there. I am running out of idea, please help.

    Hi guys, thanks for your help. I have finally get my application going with JWS. The problem was I forgot to set the MIME Type in the xml file.
    Now I have another problem, after I got my application running, I would like to try to get an applet to run. The problem is I always get 2 errors after the splash screen comes up.
    1. Unable to load resource: http://corp08/WebStart/WebStart.jar.
    I thought there was something wrong with the way I jar the files so I jar it again and get the second error.
    2. Could not find main-class com.norwestlabs.WebStart.applet.WebStartApplet in http://corp08/WebStart/WebStart.jar
    So of course I jar the files again, then the whole thing goes back to error 1, and then 2, than 1 again...
    I have check my jar file, my main file is in the root directory and I have only 1 jar file. I have also check the path in my .jnlp file, they seem to be correct.
    Here is my jnlp file:
    <?xml version="1.0" encoding="utf-8"?>
    <!-- JNLP File for Java Web Start Demo Demo Application -->
    <jnlp
    spec="1.0+"
    codebase="http://corp08/WebStart"
    href="WebStart.jnlp">
    <information>
    <title>Java Web Start Demo Application</title>
    <vendor>#Sun Microsystems, Inc.</vendor>
    <homepage href="temp2.html"/>
    <description>Java Web Start Demo Application.</description>
    <description kind="short">A demo of the capabilities of the Java Web Start Demo.</description>
    <offline-allowed/>
    </information>
    <resources>
    <j2se version="1.3"/>
    <jar href="WebStart.jar"/>
    </resources>
    <applet-desc
    documentBase="http://corp08/WebStart"
    name="WebStartApplet"
    main-class="com.norwestlabs.WebStart.applet.WebStartApplet"
    width="527"
    height="428">
    <param name="archive" value="WebStart.jar"/>
    </applet-desc>
    </jnlp>
    Please help.
    Thanks,
    Noel

Maybe you are looking for

  • [CS3 JS] How to force XMP metadata update for a thumbnail?

    Hi Folks, In a JavaScript in Bridge CS3, I'm updating a value in the XMP metadata for a Thumbnail. Later in the script I want to read the updated XMP metadata information from the Thumbnail, but often Bridge hasn't updated the metadata by the time I

  • Skype cant connect on Mac

    Hi, I am currently using the newest version of skype on my mac book air and after the update I could log in just fine, although just today I tried uninstalling and even changing my password on my phone to login to my skype but the message "skype cant

  • Plz Give me real time file to file scenarios in sap xi

    Hello Experts,    Can any one give me the real time file2file scenarios in sap xi. And differnet file structures and different 'File Content Conversion'  objects. Explain me different approch for file2file with different scenarios. Thanks in advance.

  • A PERMANENT fix to crashing Apps?

    I have the iPod Touch 2g, with 3.0 firmware installed, NOT JAILBROKEN! As most people know, ALL installed Apps keep crashing. I want to know a PERMANENT fix to this. <edited by host> I don't always have internet/WiFi access 24/7/365. I DO go out a lo

  • How do I disable iMessage for my phone number?

    I recently upgraded my iPhone 3GS to a Samsung Galaxy S3.  Consequently, I now no longer use iMessage.  My wife has an iPhone 5 and when she tries to message me, it always tries to send as an iMessage instead of a standard SMS message. I have done th