Al.exe Tool Errors and Warnings
The following table lists the errors generated by Al.exe.
Internal compiler error
Try to determine whether Al.exe is failing because of its inability to parse unexpected syntax. Then, contact Microsoft Product Support Services.
Out of memory
Al.exe ran out of memory and stopped. Increase the amount of available memory.
Compiler option 'option' must be followed by an argument
Al.exe expected an argument to be passed to a command-line option. For example, if you specify /algid:, you must pass an algorithm identifier.
Unexpected common language runtime initialization error — 'reason'
Al.exe reported an error with the installation of Visual Studio or the common language runtime for the specified reason.
File 'file' too big to open
All files opened by Al.exe must be smaller than 4 gigabytes (GB).
Response file 'file' was already included
The same response file was specified (@file) more than once on the command line. The response file can only be included once.
Error opening response file 'file' — 'reason'
Al.exe cannot open the specified response file for the specified reason.
Missing file specification for 'option' command-line option
Al.exe expected a file to be passed to a command-line option. For example, if you specify the /out option, you must specify a file.
Can't open 'file' for writing
Al.exe was unable to write to a file, such as the output assembly file. The disk might be full, the file might be read-only, or you might not have permissions to the file.
Command-line syntax error: Missing ':text' for 'option' option
Al.exe expected an argument to be passed to a command-line option. For example, if you specify the /title option, you must pass a string.
File 'file' is an executable file and cannot be opened as a text file
A binary file was specified where a text file was expected. For example, this error occurs if a binary file is passed on the command line as a response file.
'value' is not a valid setting for option 'option'
An unexpected value was passed to a command-line option. For example, this error occurs if you specify an invalid value to the /target option.
Unrecognized command-line option: 'option'
An invalid command-line option was specified.
Unexpected initialization error — 'reason'
Al.exe detected a COM initialization failure. This might be caused by a lack of memory, but a more likely cause is the system DLL files. You should see a similar error if you run any Automation-aware or COM-aware program, such as Microsoft Visual Studio.
Reinstall the operating system.
Unable to find messages file 'alinkui.dll'
Al.exe requires Alinkui.dll. Make sure that this file is on your path. If necessary, copy it from the product CD.
No valid input files were specified
Al.exe requires one or more input files that do not have assembly information.
No target file name was specified
The required /out option specifying the target file name was missing.
Required file 'file' could not be loaded
Certain DLL files cannot be loaded. Reinstall Visual Studio or the Windows Software Development Kit (SDK).
Metadata failure while creating assembly — reason
Generation of the assembly was interrupted for the specified reason. For example, this error occurs if a file that you specify with the /win32res option is not found.
Ignoring included assembly 'file'
An input file that contained an assembly was specified. Al.exe input files cannot contain assemblies.
'setting' : overriding previous setting
A module had a value for a particular setting, possibly assigned through custom attributes, which was overridden with a value passed using an Al.exe command-line option.
Error reading embedded resource 'file' — reason
Al.exe cannot read the file passed to the /embedresource option for the specified reason.
Error embedding resource 'file' — reason
The operating system cannot embed the resource file in the assembly for the specified reason.
ComType record 'record' points to an invalid file record 'record'
Metadata in the input module is invalid. The tool that produced the module must be fixed.
The version specified 'version' is invalid
See information about the /version option for valid formats.
Key file 'file' is missing the private key needed for signing
A key file that contains only the public key was passed to the /keyfile option. Use the Strong Name Tool (Sn.exe) to generate a file that has both a public and private key, as shown in the following command.
sn -k keypair.snk.
The key container name 'container' does not exist
The value passed to the /keyname option is not a valid container. Use the Strong Name Tool (Sn.exe) to create a container.
The cryptographic service is not installed properly or does not have a suitable key provider
You might have to either reinstall the operating system or install some cryptographic utility that was that is used to create the key.
Error reading icon 'file' — reason
Al.exe cannot read the file that was passed to the /win32icon option for the specified reason
Error generating resources for 'file' — reason
Al.exe cannot create a file because of insufficient disk space or some other error. This error occurs when you specify the /win32icon option (which generates an .ico file) or do not specify the /win32res option (which generates a file that has resource information).
If you cannot resolve the file generation problem, use /win32res, which specifies a file that can contain version or bitmap (icon) information.
Assembly custom attribute 'attribute' was specified multiple times with different values
Different values were passed to two occurrences of the same custom attribute in source modules that are specified as input to Al.exe.
Assembly 'file' cannot be copied or renamed
While using the Al.exe syntax that enables you to both specify an input file and copy it, a name conflict arose that stopped the compiler. For example, this error occurs if you specify input.dll,somename.dll /out:somename.dll.
Libraries cannot have an entry point
You cannot specify both the /target:lib option (the default) and the /main option.
Entry point required for executable applications
When using the /target:exe or /target:win option, you must also specify the /main option.
Unable to find the entry point method 'main'
Al.exe cannot find a Main method at the location specified by the /main option.
Initialization of global assembly cache manager failed — reason
Reinstall Visual Studio or the Windows SDK.
Failed to install assembly into cache — reason
Only signed assemblies can be installed into the cache. See Global Assembly Cache for more information.
'method': cannot be the entry point because the signature or visibility is incorrect, or it is generic
A method was specified with the /main option, but that method is not static, does not return int or void, was generic, or has invalid arguments.
'exe': EXEs cannot be added modules
An .exe file that does not have an assembly was specified as an input file to Al.exe. Al.exe can only take .dll files without assemblies as input files.
Manifest file name 'name' cannot be the same as any modules
The name specified with the /out option cannot be the same as any one of the file names that are specified as input to Al.exe.
Error reading key file 'file' — reason
An error occurred while opening or reading from a file specified with /keyfile or the AssemblyKeyFileAttribute.
Filename 'file' is too long or invalid
A file name longer than 260 characters was passed to Al.exe. Choose a file name with fewer characters or a shorter path, or rename the file.
Resource identifier 'ID' has already been used in this assembly
Two resources, embedded or linked, have the same identifier or name (the second argument). Remove or rename one of the conflicting resources.
Error importing file 'file' — reason
A module file cannot be opened for the specified reason.
Error importing module 'module' of assembly 'assembly' — reason
An error occurred when opening a nonmanifest file of a multifile assembly. This error is not emitted directly by Al.exe, but can be passed programmatically to a process that uses Al.exe.
Cannot auto-generate build and revision version numbers for dates before January 1, 2000
The system clock on your computer is set to a date earlier than January 1, 2000.
The feature you are using 'old feature' is no longer supported; please use 'new feature' instead
A feature previously supported by Al.exe is now obsolete. Use the recommended feature instead.
Error emitting 'attribute' attribute —'reason'
An assembly custom attribute was not processed by Al.exe for the specified reason.
File 'filename' is not an assembly
The file specified with /template must contain assembly metadata. This error indicates that the file specified by /template did not contain an assembly.
The version 'version' specified for the 'option' is not in the normal 'major.minor.build.revision' format
Al.exe detected ill-formed version information specified with the /fileversion or /productversion options.
The version 'version' specified for the 'option' is not in the normal 'major.minor.build.revision' format
Al.exe detected ill-formed version information specified with the SatelliteContractVersionAttribute.
Referenced assembly 'filename' does not have a strong name
This error is issued when you are building an assembly with a strong name and reference an assembly that does not have a strong name. To fix this, you must either regenerate your assembly with a strong name, or attach a strong name to the assembly by using sn.exe (see the documentation for sn.exe).
A common occurrence of this error is when you are using COM objects by way of wrapper assemblies, such as when you add a reference to a COM module to a C# project by way of the Visual Studio IDE. To avoid the error, you can specify the strong name key file for COM wrapper assemblies in the Project Property "Wrapper Assembly Key File/Name"
If you are creating the wrapper assembly through tlbimp, see the tlbimp documentation for information about how to assign a strong name to the wrapper assembly.
If an assembly has a strong name, it can be installed in the global assembly cache. Consequently, referenced assemblies would also go into the global assembly cache. Only assemblies with strong names can go into the global assembly cache.
Referenced assembly 'filename' is a localized satellite assembly
An assembly created by using the AssemblyCultureAttribute attribute was referenced in creating the current assembly. The AssemblyCultureAttribute attribute indicates the file is a localized satellite assembly and it is not appropriate to reference a satellite assembly. You should probably reference the main parent assembly instead.
Executables cannot be localized, Culture should always be empty
An assembly is being created by using /target:exe but /culture was specified. Assemblies in the .exe cannot have information in the Culture field.
'file' is an assembly and cannot be added as a module
In a C++ compilation, /assemblymodule (linker option) was passed a file that contained an assembly.
Unknown error (code)
Al.exe received an unknown error code (code).
Possible solutions include the following:
Cryptographic failure while creating hashes — reason
An error occurred while creating the file hashes for a multifile assembly.
Cannot set option 'option' because 'reason'
The value specified for this option is invalid for the specified reason.
Module 'module' was specified multiple times; it will only be included once
This warning is generated when the same source, input, or module file is specified multiple times on the command line. Make sure that you specify the file name only once.
Public type 'type' is defined in multiple locations in this assembly: 'file1' and 'file2'
The same type was found in more than one module in the assembly. Only one version of each type may be present in an assembly.
Cannot specify multiple /bugreport options.
Only one /bugreport option is allowed.
File name 'File Name' is too long or invalid
The specified file name is longer than the maximum allowed.
Character 'character' is not allowed on the command-line or in response files
An invalid character was found, either on the command line or in a file.
'filename' is a binary file instead of a text file
The file is in binary format instead of text.
Module 'ModuleName' is already defined in this assembly. Each linked resource and module must have a unique file name.
The module occurs more than once in this assembly.
Cannot create short file name 'filename' when a long file name with the same short file name already exists
The current file has a name that is the short version of a file name that already exists. For example, compiling LongFileName.cs and then recompiling with the name LongFi~1.cs will cause a compiler error similar to this. If the compiler output files that have long names were deleted, but the analogous linker files remained, this error might occur.
Agnostic assembly cannot have a processor specific module 'Module Name'
If you are building using /platform:agnostic (or you don’t specify /platform), an error will be generated if you try to add a module (using /addmodule) that is not agnostic. This is like trying to link an i386 obj file to an ia64 obj.
The main source of non-agnostic modules is C++. If you are using /addmodule with a C++ module, you may have to modify your build scripts to specify the appropriate /platform setting.
Assembly and module 'Module Name' cannot target different processors
You cannot link an assembly and a module that are targeted for different processors, because the result has to run on a single processor.
Referenced assembly 'assembly' targets a different processor
You cannot link assemblies that are targeted for different processors, because the result has to run on a single processor.
Module name 'Module Name' stored in 'File Name' must match its file name
This is required of the linker. To resolve this problem, make the two names match.
Delay signing was requested, but no key was given
When an assembly is delay signed, the compiler does not compute and store the signature, but reserves space in the file so the signature can be added later.
For example, using /delaysign+ enables a tester to put the assembly in the global cache. After testing, you can fully sign the assembly by adding the private key to the assembly by using the Assembly Linker utility.
Type 'type' is forwarded to multiple assemblies: 'assembly' and 'assembly'.
A type can only be forwarded to one assembly.
Public type 'type' is defined in 'assembly' and forwarded to 'assembly'.
There is a duplicate public type in the assembly being generated. One is a valid type definition and the other is a type forwarder.