ModernJava
http://www.modernminds.com
T roubleshooting Tips

This page contains some tips to help you if the WildView applet is not performing the way that you expect it to perform.

This document is divided into two section: there is a Questions and Answers section, and a General Tips section.

If you are unable to solve the problem after reviewing these tips, please submit a bug report.
Q uestions and Answers

To find the answer to a question listed below, just click on the question.
I just finished adding a WildView applet to my web page, but when I pull it up in a browser, I only see an empty rectangle. Why?
For some reason my JPEG image file isn't loading. What's going on?
I'm using Netscape Navigator 3.01 and the colors in my image files are all screwed up. How can I fix it?
When my WildView applet loads, the background is drawn, but nothing else happens. What's wrong?
When my WildView applet loads, some or most of the panels are displayed, but some panels are not displayed. Why is this?
I'm using Internet Explorer 3.02 and when I load the applet from my local file system I get a "Security Exception." The applet runs fine when loaded from my web server, why won't it run when I load it locally?
Why are there no "cab" or "zip" files included with WildView?


Q   I just finished adding a WildView applet to my web page, but when I pull it up in a browser, I only see an empty rectangle. Why?

A   If the WildView applet area on your web page is empty, then most likely you have specified something incorrectly that has confused the applet so much that it can't initialize. Here are some things to check:

  1. Check the applet parameters to make sure that all of the values are correct and valid.

  2. Check the location of the files (i.e., the Java class files and your own files).

  3. Check the Panel Set Tags and Attributes to make certain that you didn't leaving something out or type something incorrectly.

  4. If all else fails, check the Java output log. This may provide you with clues as to what's going wrong.
If none of the above suggestions help, please collect as much information as possible (e.g., your HTML file, your panel set layout file, a listing of the Java output log, etc.) and submit a bug report to Modern Minds.


Q   For some reason my JPEG image file isn't loading. What's going on?

A   The first thing to verify is that the JPEG's file name and location is correctly entered.

Next, take a look at the Java output log. The Java output log will often provide you with information that will tell you the cause of the problem.

If the Java output log has a message that is similar to:

sun.awt.image.ImageFormatException: JPEG datastream contains no image

then the browser is having a problem understanding the internal format of your JPEG file.

This problem with reading JPEGs has only been reported when Netscape Navigator 3.01 is being used as the browser -- you should not encounter this problem with Microsoft Internet Explorer or with Netscape Communicator (i.e., Navigator 4.0).

If you have used Adobe Photoshop 4.0 to create your JPEG image, you will need to make a setup adjustment and then re-save the image. In Photoshop 4.0, select "Preferences" from the File menu, and then choose "Saving Files...". Select "Never Save" from the Image Previews pop-up menu, and then re-save your JPEG file. You won't see an image preview in Photoshop's open-file dialog, but the image should now work with Java applets.

If you did not use Photoshop 4.0 to create your JPEG or if you are still encountering a problem, then try re-saving the file, but keep the JPEG save options as basic as possible. Also, try using a lower "quality" setting -- sometimes saving a JPEG with a "high quality" setting will cause this problem.

Keep in mind that if you re-save a JPEG, you must shut-down the browser and re-launch it in order for the Java applet to load the new version of your image file.


Q   I'm using Netscape Navigator 3.01 and the colors in my image files are all screwed up. How can I fix it?

A   Netscape Navigator 3.01 seems to have a problem when a Java program draws a graphic file image which uses a color pallet that does not match the Navigator standard pallet. In this case, Navigator dithers, or changes, the colors in the image to match its standard pallet.

Sometimes if the Java applet performs an image processing operation on the image, the image is displayed incorrectly. Other times a GIF image might be dithered even though nothing has been done to the image by the applet.

Unfortunately, there are no hard and fast rules to fix this problem. It is suggested that you try changing the image's color pallet to the standard Netscape color pallet, or that you try adjusting the image with a graphics program to minimize (or possibly eliminate) the color problems.

This problem is not a problem with the applet: it is a problem with Netscape Navigator 3.01.

You should not encounter this error with Microsoft Internet Explorer or with Netscape Communicator (i.e., Navigator 4.0).


Q   When my WildView applet loads, the background is drawn, but nothing else happens. What's wrong?

A   Check to make certain that the file name specified for the panelSet applet parameter is spelled and capitalized correctly, and also that the file is located in the correct directory.

If WildView cannot locate your panel set file, then it will log an error message and will display only the background that you defined for the WildViewdisplay.


Q   When my WildView applet loads, some or most of the panels are displayed, but some panels are not displayed. Why is this?

A   First check the size of your panel set file. If the file size is greater than 16 KB, then WildView is only reading part of your file unless you have specified a value greater than 16 for the "maxSizeKB" applet parameter (the parameter value defaults to 16 if you omit it in the HTML).

If your panel set file is smaller than 16 KB, or if you have specified a value greater than the panel set size for the "maxSizeKB" applet parameter, then there might be an invalid value in a panel set that is causing an error. Check the Java output log to determine if this is the case.


Q   I'm using Internet Explorer 3.02 and when I load the applet from my local file system I get a "Security Exception." The applet runs fine when loaded from my web server, why won't it run when I load it locally?

A   An early release of Microsoft Internet Explorer 3.02 made a change to the security model in the Java Virtual Machine that prevents applets from loading files in some instances.

Microsoft has since relaxed the security restrictions and has released an updated version of the Java Virtual Machine.

You can download the latest Java Virtual Machine from Microsoft at http://www.microsoft.com/Java (look for a link that points to the "Java VM Update").


Q   Why are there no "cab" or "zip" files included with WildView?

A   CAB and ZIP files are files that can be used to improve the time that is required to transfer the applet class files to the computer that will run the Java applet.

While CAB and ZIP files can certainly be used with WildView, it was not practical to include pre-built CAB and ZIP files because of the great number of combinations that are possible with WildView.

If you are interested in creating your own CAB and/or ZIP file that is customized for your particular WildView applet design, you can obtain information regarding CAB files at the Microsoft site http://www.microsoft.com/workshop/prog/cab/. Information about using a ZIP file should be found in any good HTML reference book (look for the section that describes the <APPLET> tag).
G eneral Tips

The following are some general tips that might be of help to you if you are trying to figure out why the WildView applet doesn't seem to work.
Check the Applet Parameters

Many common problems occur when the WildView applet parameter names or the WildView applet parameter values are specified incorrectly. For each PARAM tag in the WildView applet tag, make sure that the spelling and capitalization of each NAME and VALUE is correct.

Also, make sure that you understand the effect that each parameter has and what (if any) additional parameters might be required. The documentation should have all the information you need.
Check the Panel Set Tags and Attributes

Make certain that all of the tag names are capitalized (e.g., <PANEL>, <TRIGGER>, <WAIT>, etc). Tag attribute names may be in lower case or mixed case (they are converted to lower case internally), but tag names must always be upper case.

Tag attribute values are always converted to lower case unless they are surrounded by quotation marks. If you specify a file name for an attribute value and forget to surround it with quotation marks, then the file will not be found if it has any upper case characters in the file name.

For instance, the tag shown below will generate two errors:

<PANEL name=image2 module=WVPanelImage image=MyPicture.JPG ... >

because (1) the module name does not have quotation marks, and (2) the image name does not have quotation marks.

The tag should look like:

<PANEL name=image2 module="WVPanelImage" image="MyPicture.JPG" ... >

Finally, make sure that you understand the effect that each attribute has and what (if any) additional attributes might be required. The documentation should have all the information you need.
Check the Output Log

If an error occurs in a Modern Minds Java applet, the applet will usually log an error message to the console or to a log file. By reviewing the error message, you can often determine why the applet is not working (e.g., a missing or misspelled parameter).

Microsoft's Internet Explorer 3.x creates a log file (for Windows95, it is usually found as C:\WINDOWS\JAVA\javalog.txt), but only if the Java logging option is enabled. To enable Java logging, select Options from the View menu, then select the Advanced tab. Next, click the Enable Java Logging checkbox. After enabling Java Logging, you will need to shut down your browser and restart it.

If you are using Netscape Navigator, you can view error messages by selecting Show Java Console from the Options menu.

Netscape Communicator (Navigator 4) will display the Java Console if you select the Java Console option from the Communicator menu.

For other browsers, please consult your browser's documentation to determine how Java logging is performed.
Check Where the Classes and Files are Located

The WildView applet expects to find its Java classes (the software code) and the files that you are using in your WildView design in a specific location. Where that location actually is depends upon how the <APPLET> tag is defined in your HTML, and also upon any paths that you have specified for files.

If WildView cannot find its classes or your files because you have entered something incorrectly, then the applet will either not work, or it will work, but it will not work the way that you are expecting.

If you are unsure of how the <APPLET> tag works, or if you are not sure that you specified the path to a file correctly, please look at the applet tag documentation and the Where the Pieces Go documentation.
Copyright © 1997 by Modern Minds, Inc.