Windows EXE/COM DLL Packaging Errors (Visual J++)

During the creation of a Windows EXE or COM DLL, you may be receive an error message. The following is a list of the error messages that might occur. Each error includes information as to the possible reasons the error occurred and, where applicable, suggestions on how to resolve the error.

Path too long: 'path'

The path and filename of a Windows EXE or COM DLL is larger than 256 characters. Reduce the size of the path and filename and rebuild your project.

No main class file specified

An attempt was made to create a Windows EXE but a main class (a class with a main method defined) was not specified. In order for a Windows EXE to be created, you must specify a main class in the Launch tab of the Project Properties dialog box.

No class files found

An attempt was made to create a Windows EXE or COM DLL but no class files were found or specified to create the EXE or DLL. Ensure that your project contains at least one class file and that a class file is specified in the Output Format tab of the Project Properties dialog box.

Unable to open output file: 'filename'

The file specified in the error message could not be opened. Ensure that the specified file is not read-only or in use by another program. This error can also occur if the specified file is located in a directory in which you do not have write permission.

Unable to update resources in file: 'filename'

An attempt was made to write resource information to the resource file specified in the error message, but was unable to update the resource file. Ensure that you have enough available free disk space on your computer.

Badly formatted class file: 'filename'

The class file specified in the error message is in an invalid format. This error usually occurs when a class file is damaged or is a file with the class extension, but is not a valid Java class file. Delete the class file specified in the error message and rebuild your project.

File not found: 'filename'

The file specified in the error message was not found. Ensure that the proper location of the file is specified in the Output Format tab of the Project Properties dialog box and rebuild your project.

Unable to load resources from file 'filename'

The resource file specified in the error message could not be opened. Ensure that the resource file is a valid Windows resource file and that the resource file is not in use by another program.

Unable to read typelib file 'filename'

The type library file specified in the error message could not be opened. Ensure that the type library file is a valid type library file and that the file is not in use by another program.

Corrupt registration attribute in class 'identifier'

A COM registration attribute for the class specified in the error message is corrupt. This error usually occurs when the class file for the specified class is damaged or in an invalid file format. Delete the class file for the specified class and rebuild your project.

Class 'identifier' does not have a method of the form 'static public void main (String[])'

A class was specified as the main class of a Windows EXE, but the class did not contain a main method. The main method provides a starting point for the Windows EXE and must be specified. Add a main method to the class specified in the error message or choose a different main class in the Launch tab of the Project Properties dialog box and rebuild your project.

Main class name 'identifier' is too long

The main class name specified in the error message is larger than 256 characters. Reduce the size of the class name and rebuild your project.

Specified main class 'identifier' not found

While creating a Windows EXE file, the class specified as the main class for the Windows EXE was not found. This error usually occurs when a main class was specified in the Launch tab of the Project Properties dialog box, but the main class has been removed or renamed from the class file. Specify a new main class in the Launch tab of the Project Properties dialog box and rebuild your project.

Unable to read from file 'filename'

The file specified in the error message could not be opened for reading. Ensure that the specified file is not in use by another program.

Cannot create a DLL with no COM classes

An attempt was made to create a COM DLL, but the project does not contain any COM classes. You can create a COM class by selecting a class from the list of classes in the COM Classes tab of the Project Properties dialog box. If you do not wish to expose any of your classes as COM classes, change the type of package you want to create in the Output Format tab of the Project Properties dialog box and rebuild your project.

Failure during auto-registration of 'filename'

A COM DLL failed to auto-register after being created. This error usually occurs when the system registry is damaged.

Out of memory

Insufficient memory was available when creating a Windows EXE or COM DLL. Close other programs that are currently running to provide more available memory and rebuild your project.