Error J0051: Undefined package 'Lang' (169799)
The information in this article applies to:
- Microsoft Visual J++ 1.0
- Microsoft Visual J++ 1.1
- Microsoft Visual J++ 6.0
- Microsoft SDK for Java 2.0
- Microsoft SDK for Java 2.01
- Microsoft SDK for Java 2.02
- Microsoft SDK for Java 3.0
- Microsoft SDK for Java 3.1
- Microsoft virtual machine
- Microsoft Internet Explorer (Programming) 1.0
- Microsoft Internet Explorer (Programming) 2.0
- Microsoft Internet Explorer (Programming) 2.01
- Microsoft Internet Explorer (Programming) 2.1
- Microsoft Internet Explorer (Programming) 3.0
- Microsoft Internet Explorer (Programming) 3.01
- Microsoft Internet Explorer (Programming) 3.02
- Microsoft Internet Explorer (Programming) 4.0
- Microsoft Internet Explorer (Programming) 4.01
- Microsoft Internet Explorer (Programming) 4.01 SP1
- Microsoft Internet Explorer (Programming) 4.01 SP2
- Microsoft Internet Explorer (Programming) 5_beta
This article was previously published under Q169799 IMPORTANT: This article contains information about editing the registry.
Before you edit the registry, make sure you understand how to restore it if
a problem occurs. For information about how to do this, view the "Restoring
the Registry" Help topic in Regedit.exe or the "Restoring a Registry Key"
Help topic in Regedt32.exe.
SYMPTOMS
The following compiler error appears when you try to build simple Java
applets or applications:
error J0051: Undefined package 'lang'
This article discusses the possible reasons why this error occurs.
( NOTE: This is not specific to the 'lang' package, but could occur for
any package whether implicitly or explicitly imported.)
CAUSE
This problem often occurs after installing a virtual machine for Java that supports the
Java Package Manager (JPM). Beginning with Microsoft virtual machine (Microsoft VM) build 2252 (installed
with Internet Explorer 4.0x or the SDK for Java 2.0x) and later, the JPM contains all the
system classes. These Microsoft VM builds no longer require a Classes.zip file on the
classpath at run-time.
Compilers that do not search the JPM will need to find the system classes
on the conventional classpath (<windir>\java\classes). To create a single
zip file that contains all the system classes, see the RESOLUTION section
of this article.
RESOLUTION
The MORE INFORMATION section contains a checklist that provides some of the
common fixes for this error.
REFERENCESFor additional information about obtaining the latest version of the Microsoft VM, click the article numbers below
to view the articles in the Microsoft Knowledge Base:
163637 INFO: Availability of Current Build of Microsoft VM
For support information about Visual J++ and the SDK for Java, visit the following Microsoft Web site:
Modification Type: | Major | Last Reviewed: | 6/14/2006 |
---|
Keywords: | kbenv kbprb KB169799 |
---|
|