1 <?xml version="1.0" encoding="utf-8"?>
2 <Type Name="ResXFileRef" FullName="System.Resources.ResXFileRef">
3 <TypeSignature Language="C#" Value="public class ResXFileRef" />
5 <AssemblyName>System.Windows.Forms</AssemblyName>
6 <AssemblyVersion>1.0.5000.0</AssemblyVersion>
7 <AssemblyVersion>2.0.0.0</AssemblyVersion>
10 <BaseTypeName>System.Object</BaseTypeName>
15 <AttributeName>System.ComponentModel.TypeConverter(typeof(System.Resources.ResXFileRef+Converter))</AttributeName>
20 <attribution license="cc4" from="Microsoft" modified="false" />
21 <para>The <see cref="T:System.Resources.ResXFileRef" /> class is used to include references to files in an XML resource (.resx) file. A <see cref="T:System.Resources.ResXFileRef" /> object represents a link to an external resource in an XML resource (.resx) file. You add the <see cref="T:System.Resources.ResXFileRef" /> object to a .resx file by calling the <see cref="M:System.Resources.ResXResourceWriter.AddResource(System.Resources.ResXDataNode)" /> method. </para>
22 <para>In a data entry in a .resx file, the type is <see cref="T:System.Resources.ResXFileRef" />, and the value is the path location on disk. When the resource manager deserializes the object, the <see cref="T:System.Resources.ResXFileRef" /> performs the I/O to get the file. The following is an example of a .resx file. </para>
23 <code> <data name="iconclip" type="System.Resources.ResXFileRef, System.Windows.Forms">
24 <value>lookout.bmp;System.Drawing.Bitmap, System.Drawing</value>
26 <data name="mailbackground" type="System.Resources.ResXFileRef, System.Windows.Forms">
27 <value>mailbackground.bmp;System.Drawing.Bitmap, System.Drawing</value>
29 <data name="xplogo" type="System.Resources.ResXFileRef, System.Windows.Forms">
30 <value>xplogo.png;System.Drawing.Bitmap, System.Drawing</value>
32 <para>To add a <see cref="T:System.Resources.ResXFileRef" /> object to a .resx file programmatically, you call the <see cref="M:System.Resources.ResXDataNode.#ctor(System.String,System.Resources.ResXFileRef)" /> constructor to instantiate a <see cref="T:System.Resources.ResXDataNode" /> object. You then pass this <see cref="T:System.Resources.ResXDataNode" /> object to the <see cref="M:System.Resources.ResXResourceWriter.AddResource(System.Resources.ResXDataNode)" /> method. </para>
33 <para>When you compile a .resx file with <format type="text/html"><a href="8ef159de-b660-4bec-9213-c3fbc4d1c6f4">Resgen.exe (Resource File Generator)</a></format>, the resources specified in the .resx file are embedded in the resulting document resource file.</para>
36 <attribution license="cc4" from="Microsoft" modified="false" />
37 <para>Represents a link to an external resource.</para>
41 <Member MemberName=".ctor">
42 <MemberSignature Language="C#" Value="public ResXFileRef (string fileName, string typeName);" />
43 <MemberType>Constructor</MemberType>
45 <Parameter Name="fileName" Type="System.String" />
46 <Parameter Name="typeName" Type="System.String" />
50 <attribution license="cc4" from="Microsoft" modified="false" />
51 <para>The type referred to by the <paramref name="typeName" /> parameter must support a public constructor that accepts a <see cref="T:System.IO.Stream" /> object as a parameter.</para>
54 <attribution license="cc4" from="Microsoft" modified="false" />
55 <para>Creates a new instance of the <see cref="T:System.Resources.ResXFileRef" /> class that references the specified file.</para>
57 <param name="fileName">
58 <attribution license="cc4" from="Microsoft" modified="false" />The file to reference. </param>
59 <param name="typeName">
60 <attribution license="cc4" from="Microsoft" modified="false" />The type of the resource that is referenced. </param>
63 <AssemblyVersion>1.0.5000.0</AssemblyVersion>
64 <AssemblyVersion>2.0.0.0</AssemblyVersion>
67 <Member MemberName=".ctor">
68 <MemberSignature Language="C#" Value="public ResXFileRef (string fileName, string typeName, System.Text.Encoding textFileEncoding);" />
69 <MemberType>Constructor</MemberType>
71 <AssemblyVersion>2.0.0.0</AssemblyVersion>
74 <Parameter Name="fileName" Type="System.String" />
75 <Parameter Name="typeName" Type="System.String" />
76 <Parameter Name="textFileEncoding" Type="System.Text.Encoding" />
80 <attribution license="cc4" from="Microsoft" modified="false" />
81 <para>The type referred to by the <paramref name="typeName" /> parameter must support a public constructor that accepts a <see cref="T:System.IO.Stream" /> object as a parameter.</para>
84 <attribution license="cc4" from="Microsoft" modified="false" />
85 <para>Initializes a new instance of the <see cref="T:System.Resources.ResXFileRef" /> class that references the specified file. </para>
87 <param name="fileName">
88 <attribution license="cc4" from="Microsoft" modified="false" />The file to reference. </param>
89 <param name="typeName">
90 <attribution license="cc4" from="Microsoft" modified="false" />The type name of the resource that is referenced. </param>
91 <param name="textFileEncoding">
92 <attribution license="cc4" from="Microsoft" modified="false" />The encoding used in the referenced file.</param>
95 <Member MemberName="FileName">
96 <MemberSignature Language="C#" Value="public string FileName { get; }" />
97 <MemberType>Property</MemberType>
99 <AssemblyVersion>2.0.0.0</AssemblyVersion>
102 <ReturnType>System.String</ReturnType>
105 <value>To be added.</value>
106 <remarks>To be added.</remarks>
108 <attribution license="cc4" from="Microsoft" modified="false" />
109 <para>Gets the file name specified in the current <see cref="Overload:System.Resources.ResXFileRef.#ctor" /> constructor.</para>
113 <Member MemberName="TextFileEncoding">
114 <MemberSignature Language="C#" Value="public System.Text.Encoding TextFileEncoding { get; }" />
115 <MemberType>Property</MemberType>
117 <AssemblyVersion>2.0.0.0</AssemblyVersion>
120 <ReturnType>System.Text.Encoding</ReturnType>
123 <value>To be added.</value>
124 <remarks>To be added.</remarks>
126 <attribution license="cc4" from="Microsoft" modified="false" />
127 <para>Gets the encoding specified in the current <see cref="Overload:System.Resources.ResXFileRef.#ctor" /> constructor.</para>
131 <Member MemberName="ToString">
132 <MemberSignature Language="C#" Value="public override string ToString ();" />
133 <MemberType>Method</MemberType>
135 <ReturnType>System.String</ReturnType>
139 <returns>To be added.</returns>
140 <remarks>To be added.</remarks>
142 <attribution license="cc4" from="Microsoft" modified="false" />
143 <para>Gets the text representation of the current <see cref="T:System.Resources.ResXFileRef" /> object.</para>
147 <AssemblyVersion>1.0.5000.0</AssemblyVersion>
148 <AssemblyVersion>2.0.0.0</AssemblyVersion>
151 <Member MemberName="TypeName">
152 <MemberSignature Language="C#" Value="public string TypeName { get; }" />
153 <MemberType>Property</MemberType>
155 <AssemblyVersion>2.0.0.0</AssemblyVersion>
158 <ReturnType>System.String</ReturnType>
161 <value>To be added.</value>
162 <remarks>To be added.</remarks>
164 <attribution license="cc4" from="Microsoft" modified="false" />
165 <para>Gets the type name specified in the current <see cref="Overload:System.Resources.ResXFileRef.#ctor" /> constructor. </para>