ResXFileRef Class
Represents a link to an external resource.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
The ResXFileRef type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | ResXFileRef(String, String) | Creates a new instance of the ResXFileRef class that references the specified file. |
![]() | ResXFileRef(String, String, Encoding) | Initializes a new instance of the ResXFileRef class that references the specified file. |
| Name | Description | |
|---|---|---|
![]() | FileName | Gets the file name specified in the current ResXFileRef constructor. |
![]() | TextFileEncoding | Gets the encoding specified in the current ResXFileRef constructor. |
![]() | TypeName | Gets the type name specified in the current ResXFileRef constructor. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Gets the text representation of the current ResXFileRef object. (Overrides Object::ToString().) |
The ResXFileRef class is used to include references to files in an XML resource (.resx) file. A ResXFileRef object represents a link to an external resource. The resource manager loads the resource returned when the resource specified by the ResXFileRef object is queried.
In a data entry in a .resx file, the type is ResXFileRef, and the value is the path location on disk. When the resource manager deserializes the object, the ResXFileRef performs the I/O to get the file.
When you compile a .resx file with ResGen.exe, the resources specified in the .resx file are embedded in the resulting document resource file.
The following example shows typical contents of a .resx file.
<data name="iconclip" type="System.Resources.ResXFileRef, System.Windows.Forms"> <value>lookout.bmp;System.Drawing.Bitmap, System.Drawing</value> </data> <data name="mailbackground" type="System.Resources.ResXFileRef, System.Windows.Forms"> <value>mailbackground.bmp;System.Drawing.Bitmap, System.Drawing</value> </data> <data name="xplogo" type="System.Resources.ResXFileRef, System.Windows.Forms"> <value>xplogo.png;System.Drawing.Bitmap, System.Drawing</value> </data>
For more information about the format of a .resx file, see Resources in .resx File Format.
- InheritanceDemand
for full trust for inheritors. This class cannot be inherited by partially trusted code.
- LinkDemand
for full trust for the immediate caller. This class cannot be used by partially trusted code.
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
