Resource Class
Represents a Win32 resource which can be loaded from and saved to a PE file.
Methods
| Method | Description | 
|---|---|
| Equals(obj) | Tests if type, name, and locale of this Resource object match another Resource object. | 
| GetHashCode() | Gets a hash code for this Resource object. | 
| Load(file) | Loads the resource data from a file. The file is searched for a resource with matching type, name, and locale. | 
| Save(file) | Saves the resource to a file. Any existing resource data with matching type, name, and locale is overwritten. | 
Properties
| Property | Description | 
|---|---|
| Data | Gets or sets the raw data of the resource. | 
| Locale | Gets or sets the locale of the resource. | 
| Name | Gets or sets the name of the resource. For a numeric resource identifier, the decimal number is prefixed with a "#". | 
| ResourceType | Gets or sets the type of the resource. This may be one of the ResourceType constants or a user-defined type name. | 
WixToolset.Dtf.Resources.dll version 6.0.0+8c7432e50072e009353ea5f2c956ccf453476f71
Equals(obj) Method
Tests if type, name, and locale of this Resource object match another Resource object.
Declaration
public bool Equals(
  System.Object obj
)
Parameters
| Parameter | Type | Description | 
|---|---|---|
| obj | System.Object | Resource object to be compared | 
Return value
bool True if the objects represent the same resource; false otherwise.
GetHashCode() Method
Gets a hash code for this Resource object.
Declaration
public int GetHashCode()
Return value
int Hash code generated from the resource type, name, and locale.
Load(file) Method
Loads the resource data from a file. The file is searched for a resource with matching type, name, and locale.
Declaration
public void Load(
  string file
)
Parameters
| Parameter | Type | Description | 
|---|---|---|
| file | string | Win32 PE file containing the resource | 
Save(file) Method
Saves the resource to a file. Any existing resource data with matching type, name, and locale is overwritten.
Declaration
public void Save(
  string file
)
Parameters
| Parameter | Type | Description | 
|---|---|---|
| file | string | Win32 PE file to contain the resource | 
Data Property
Gets or sets the raw data of the resource.
Declaration
public System.Byte[] Data { get; set; } 
Locale Property
Gets or sets the locale of the resource.
Declaration
public int Locale { get; set; } 
Name Property
Gets or sets the name of the resource. For a numeric resource identifier, the decimal number is prefixed with a "#".
Declaration
public string Name { get; set; } 
ResourceType Property
Gets or sets the type of the resource. This may be one of the ResourceType constants or a user-defined type name.
Declaration
public ResourceType ResourceType { get; set; }