FieldInfo.IsLiteral Property
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Gets a value that indicates whether the value is written at compile time and cannot be changed.
Namespace: System.Reflection
Assembly: mscorlib (in mscorlib.dll)
Syntax
Public ReadOnly Property IsLiteral As Boolean
public bool IsLiteral { get; }
Property Value
Type: System..::.Boolean
true if the field has the Literal attribute set; otherwise, false.
Exceptions
Exception | Condition |
---|---|
MethodAccessException | This member is invoked late-bound through mechanisms such as Type..::.InvokeMember. |
Remarks
The IsLiteral property is set when the Literal attribute is set. If this attribute is set, the field cannot be changed and is constant.
Version Information
Windows Phone OS
Supported in: 8.1, 8.0, 7.1, 7.0
Platforms
Windows Phone