Gets the short name of the Assembly.
Namespace: log4net.Util
Assembly: log4net (in log4net.dll) Version: 2.0.6.0-.NET 4.0
Syntax
Parameters
- myAssembly
- Type: System.ReflectionAssembly
The Assembly to get the name for.
Return Value
Type: StringThe short name of the Assembly.
Remarks
The short name of the assembly is the FullName without the version, culture, or public key. i.e. it is just the assembly's file name without the extension.
Use this rather than Assembly.GetName().Name because that is not available on the Compact Framework.
Because of a FileIOPermission security demand we cannot do the obvious Assembly.GetName().Name. We are allowed to get the FullName of the assembly so we start from there and strip out just the assembly name.
See Also