MarvinSketch Applets Frequently Asked Questions MS

  • Class and JAR files

Which Java versions are supported by Marvin applets?

ChemAxon products support only Oracle distributed Java. On Mac platform (where Oracle Java is not available), our products support Apple's built-in Java that is compatible with Oracle's distribution. Marvin applets requires at least Java 1.6.

Click here to expand..Which files are required to run Marvin applets?.

Several packages can be downloaded from the Marvin site:

marvin-bin-VERSION.tar.gz or marvin-bin-VERSION.zip

Download and unpack:

zip: unzip marvin-bin-VERSION.zip
tar.gz: gunzip < marvin-bin-VERSION.tar.gz |tar xf -

This distribution contains all files necessary for using MarvinSketch and MarvinView applets, without HTML pages and examples.

marvin-all-VERSION.tar.gz and marvin-all-VERSION.zip

Download and unpack:

zip: unzip marvin-all-VERSION.zip
tar.gz: gunzip < marvin-all-VERSION.tar.gz | tar xf -

This distribution contains all files necessary for using MarvinSketch and MarvinView applets, as well as the documentation and examples.

How can I delete plugin packages from the Marvin applets package?

Remove chemaxon/marvin/plugin and sjars/plugin directories from the marvin directory.

    cd marvin
rm -r chemaxon/marvin/plugin
rm -r sjars/plugin

How can I create an unsigned jar file from a signed jar file?See the linking forum topic.

How long is the signed applet valid?

Read the following document, to check the expiration date of signing for Marvin applets: Expiration date of releases

I receive a java.lang.RuntimeException with IIS server, what's the problem? (Same: My templates are deleted)

The following exception occurs with Marvin 5.2.x versions:

    Exception in thread "AWT-EventQueue-2" java.lang.RuntimeException: java.lang.NoClassDefFoundError:
Could not initialize class chemaxon.marvin.modules.GraphInvariants
at chemaxon.marvin.util.MarvinModule.load(Unknown Source)
at chemaxon.struc.MoleculeGraph.a(Unknown Source)

IIS servers versioned 6.0 and above serve only those files that are on the mime type list of the server or web site, but some types required by Marvin are not on the list by default.

Solution: add the following mime types in the HTTP headers tab on the properties dialog of the web site or the server:

  • .properties = "text/plain"

  • .data = "application/octet-stream"

  • .mytemplates = "chemical/x-chemaxon-marvinfile"

If IIS should transfer molecule files to the clients, then the molecule file formats should also be registered with their extension.
A few commonly used extensions and the corresponding mime types are below:

  • .mrv = "chemical/x-chemaxon-marvinfile"

  • .mol = "chemical/x-mdl-molfile"

  • .cdx = "chemical/x-cdx"

  • .sdf = "chemical/x-mdl-sdfile"

  • .smi = "chemical/x-daylight-smiles"

  • .rxn = "chemical/x-mdl-rxnfile"

  • .rdf = "chemical/x-mdl-rdfile"

  • .pdb = "chemical/x-pdb"

The applet is loading but it never loads.

On the Java console a ClassNotFoundException is thrown, caused by an IOException which is thrown when the webserver reports an error to the GET request for the http://host.tld/appletpath/JMSketch.class

This problem occurs with Java 1.6.0_u15+ versions, if the Java cache is turned off.

The problem will no longer exist after Marvin 5.3, until that the Java cache is not suggested to be switched off.

Some Applet functionalities do not work.

On the Java console a ClassNotFoundException is thrown, caused by an IOException wich is thrown when the webserver reports and error to the GET request for a .class file.

This problem occurs with Java 1.6.0_u15+ versions.

The problem is caused by the 6888528 java bug. A possible solution is to clean the java cache, and redo the actions with a clean cache when this error occurs. Another solution is to turn off the "Enable the next-generation Java Plug-in" in the Java Plug-in group on the Advanced tab of the Java Control Panel.

  • MarvinSketch and MarvinView

When I put MView applets into an HTML table, I can only display about 200 molecules because the browser slows down and runs out of memory. Do you provide a simple and "thin" applet, which just displays molecules without any rotation and linkage to the sketcher?

The rotation and the linkage to the sketcher have negligible contribution to the memory footprint. The largest contributions are from

  1. double buffering of Swing components

  2. size of Molecule objects

  3. large color arrays that store the shades for 3D rendering modes

Even if we provided a "thin" applet without 3D support, it would only enable you to use about twice as many molecules. Then you would run out of memory again because of the double buffering.

You should use an n-molecule scrollable MView table instead of n applets. Then the common data will be stored in only one place (instead of n) and the number of Swing components will be equal to the number of visible molecules which is usually much smaller than n.

I do not manage to load a molecule string using an applet parameter in Mozilla.

Your molecule string may contain consecutive space characters in applet parameters which are converted to only one space. This bug applies to Mozilla 0.9.7-1.0 and probably some earlier versions too.

  • Other:

How can I set the Java environment of Firefox in Linux?

See the documentation of oOracle's Java: Manual Installation and Registration of Linux Plugin

IE can not load Marvin applets over SSL communication. I have received this warning message: "This page contains both secure and non-secure items."

The CODEBASE attribute of the OBJECT tag refers to a non-secure page that the browser does not accept. The browser downloads the plugin from this URL, if the Java Plugin is not installed on your machine.
You should change this URL to a secure one.

  1. To provide a secure page for downloading a Java Plugin, copy a JRE cab file to your site.

        http://java.sun.com/products/plugin/autodl/jinstall-1_4_2-windows-i586.cab#Version=1,3,0,0
  2. Modify the reference to this cab file in marvin.js. (Search the following code in the applet_begin function).

        s += ' CODEBASE=" http://java.sun.com/products/plugin/autodl/jinstall-1_4_2-windows-i586.cab#Version=1,3,0,0"\n';

    You should replace the text with

        s += ' CODEBASE=" https://<PLUGINLOCATION>/jinstall-1_4_2-windows-i586.cab#Version=1,3,0,0"\n';

    where <PLUGINLOCATION> is the new location of the cab file (e.g.: www.my_secure_site.com/java_plugin ).
    Note: The new URL must start with "https" protocol instead of "http".